namespaces

what's the story with the android XML namespace?

When you first use a name from the android XML namespace, you have to say where to find it, with an attribute in XML like this: <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" However, that URL is a 404 - nothing found there. The android: namespace is actually included under the locally-installed SDK. So wha...

How to register XHTML namespaces??

My page use to validate for XHTML but I added the addthis buttons to page and it gives a new namespace: E.G.: <a addthis:url="http://domain.tld/path/to/stuff" addthis:title="Teh Title here"> I tried: <html xmlns="http://www.w3.org/1999/xhtml" xmlns:addthis="http://addthis.com/" lang="en"> Doesn't work. Can we register namespac...

RIA Services - Two entity models share an entity name

I have two entity models hooked up to two different databases. However, the two databases both have a table named 'brand', for example. As such, there is a naming conflict in my models. Now, I've been able to add a namespace to each model, via Custom Tool Namespace in the model's properties, but the generated code in my Silverlight proje...

XMLOutputStream, repairing namespaces, and attributes without namespaces

A simple task: write an element two attributes: String nsURI = "http://example.com/"; XMLOutputFactory outF = XMLOutputFactory.newFactory(); outF.setProperty(XMLOutputFactory.IS_REPAIRING_NAMESPACES, true); XMLStreamWriter out = outF.createXMLStreamWriter(System.out); out.writeStartElement(XMLConstants.DEFAULT_NS_PREFIX, "element", nsUR...

Using Directives, Namespace and Assembly Reference - all jumbled up with StyleCop!

I like to adhere to StyleCop's formatting rules to make code nice and clear, but I've recently had a problem with one of its warnings: All using directives must be placed inside of the namespace. My problem is that I have using directives, an assembly reference (for mocking file deletion), and a namespace to juggle in one of my t...

Why aren't template specializations allowed to be in different namespaces?

Hi, Please, see what I am trying to do: #include <iostream> namespace first { template <class T> class myclass { T t; public: void who_are_you() const { std::cout << "first::myclass"; } }; } namespace second { using first::myclass; template <> class myclass <int> { int i, j; public: void who_are_you() const { std...

Making the nodes to ignore namespaces (prefixes) after changing XML structure. PHP DOMDocument

Hello. Original XML (myfile.xml) <?xml version="1.0" encoding="UTF-8" standalone="no"?> <blabla xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:cc="http://creativecommons.org/ns#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:blabla="http://www.w3.org/2000/blabla" xmlns="http://www.w3.org/2000/b...

SOAP, using prefixes in tags <xx:tag>

I am bad with SOAP. A third party SOAP service gave me example code to use for their api. The code that they give (which I copied to my solution EXACTLY) does not spit out a required prefix before all the tags. Right now, the code they give me causes me to make requests/responses that have no prefix to all the tags... <tagName /> . H...

XML Namespace is required ?

Hello everybody I am learning xml and xml processing.I couldn't understand existence of namespace well. I learn that Namespace help us seperate same named elements in xml.Can't we discriminate elements by attributes which has same name ? Why namespace is important or required ? I want to give an example: <persons> <person></person>...

Why can't I run my java Hello World program if it is inside a package?

I created a file called "Hello.java" that looks like this: public class Hello { public static void main(String[] args) { System.out.println("Hello, world!"); } } I ran javac Hello.java, then java Hello, and everything worked as expected. I then added the line package testpackage; to the top of the file...

Optimal extended class naming convention?

Which of the following naming conventions is most used/accepted, or which is most optimal for most projects? I'm having a hard time deciding. Base class: \Model Sub class: \Model\User Base class: \Model\Model Sub class: \Model\User Base class: \Model\Base sub class: \Model\User So in other words, should I put the base class in the s...

A simple question about LINQ to XML

<root xmlns:h="http://www.w3.org/TR/html4/" xmlns:f="http://www.w3schools.com/furniture"&gt; <h:table> <h:tr> <h:td>Apples</h:td> <h:td>Bananas</h:td> </h:tr> </h:table> <f:table> <f:name>African Coffee Table</f:name> <f:width>80</f:width> <f:length>120</f:length> </f:table> </root> I am trying to practice Li...

Load different COM files with same names (older versions) from different paths in C#

Hello, i need to build a program that load older versions of a COM DLL file and performs some operations. I've created a DLL project for each version and set the reference to the correspondent COM. After that in the main program i'm trying to load the needed assembly that load and use itself its COM. The problem is that the DLLs have Int...

C#: Can you split a namespace across multiple files?

Well I couldn't find any previous posting to answer my question so.... I am new to C# and creating some Windows Forms and noticed that it created a both Program.cs and Form1.cs files. In both, it starts with the namespace of my program "Contacts" namespace Contacts { //code here Are these compiled together, or are they still seen...

Serializing WITHOUT xmlns

I have a couple extension methods that handle serialization of my classes, and since it can be a time consuming process, they are created once per class, and handed out by this method. public static XmlSerializer GetSerializerFor(Type typeOfT) { if (!serializers.ContainsKey(typeOfT)) { var xmlAttributes = new XmlAttribut...

Do I use jQuery noconflict to avoid plugins conflict?

UPDATE: I've found that the jquery.bxslider plugin itself clones and appends/prepends the LIs causing the trouble. No solution to this though, except maybe using another script :( I'm having to jQuery plugins partially conflicting with each other, Boxslider (an image slider) and Colorbox (a lightbox). They both work, but the slider ...

Unqualified name in IDL for imported type library

I've created a COM-class that implements some interface. I want to add a method to this interface. The parameter of this method is a pointer to the interface defined in some external olb-file. In my project this olb-file imported without no_namespace directive. So, the interface name in the parameter of the method must be qualified in h\...

What does my XSLT need to do when the XML has a xmlns in it?

For the following XML <Properties ComponentID="1272040480745" Admin="true"> <Datum ID="P01" Type="File" Name="CSS To Use">style.css</Datum> <Data> <External></External> <Result> <results xmlns="http://www.interwoven.com/schema/iwrr" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.inte...

Call python function as if it were inline

I want to have a function in a different module, that when called, has access to all variables that its caller has access to, and functions just as if its body had been pasted into the caller rather than having its own context, basically like a C Macro instead of a normal function. I know I can pass locals() into the function and then it...

How to set the prefix of a document element in Delphi

Using Delphi 2009, I'm trying to get a declared namespace prefix to apply to the document element in an IXMLDocument that I'm creating. Once the document element is created I can declare a namespace with a prefix, but it does not get applied to the document element and I can't seem to change the prefix of the document element. If I use d...