dcsimg
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6

Thread: give me some declaration about namespace

Hybrid View

  1. #1
    Join Date
    Oct 2006
    Posts
    123

    give me some declaration about namespace

    hi ,
    plz i want some declaration about namespace, i know why i use namespace (establishing unique identifiers for elements and attributes) so my question, URL means the location of my document or just something to make difference among other xml objects ? what this mean in URL "ns/movies" ?
    Code:
    <movies xmlns:movie="http://www.SiteName.com/ns/movies">

  2. #2
    Join Date
    Mar 2002
    Location
    St. Petersburg, Florida, USA
    Posts
    12,116

    Re: give me some declaration about namespace

    Quote Originally Posted by honeyboy_20 View Post
    hi ,
    plz i want some declaration about namespace, i know why i use namespace (establishing unique identifiers for elements and attributes) so my question, URL means the location of my document or just something to make difference among other xml objects ? what this mean in URL "ns/movies" ?
    Code:
    <movies xmlns:movie="http://www.SiteName.com/ns/movies">
    It is for uniqueness.

    It is presumes that anyone publishing information will have a domain, so that is the first part. Specificlly for your sample, the owners of SiteName look like they decided to group all of the namespaces into an "ns" category (quite common) and then put the specific informaion.
    TheCPUWizard is a registered trademark, all rights reserved. (If this post was helpful, please RATE it!)
    2008, 2009,2010
    In theory, there is no difference between theory and practice; in practice there is.

    * Join the fight, refuse to respond to posts that contain code outside of [code] ... [/code] tags. See here for instructions
    * How NOT to post a question here
    * Of course you read this carefully before you posted
    * Need homework help? Read this first

  3. #3
    Join Date
    Oct 2006
    Posts
    123

    Re: give me some declaration about namespace

    Quote Originally Posted by TheCPUWizard View Post
    It is for uniqueness.

    It is presumes that anyone publishing information will have a domain, so that is the first part. Specificlly for your sample, the owners of SiteName look like they decided to group all of the namespaces into an "ns" category (quite common) and then put the specific informaion.
    thanks, but "ns" is just label to say my namespaces which i determine have this URL? where is info ? does this info stored ?

  4. #4
    Join Date
    Mar 2002
    Location
    St. Petersburg, Florida, USA
    Posts
    12,116

    Re: give me some declaration about namespace

    Quote Originally Posted by honeyboy_20 View Post
    thanks, but "ns" is just label to say my namespaces which i determine have this URL? where is info ? does this info stored ?
    I can not make sense of your questions.

    Once again, (just like a programming namespace) and XML namespace is simply a means to prevent "collisions" between names. The only differences is that a programming namespace must (typically) have the format of a series of identifiers separated by a delimiter, XML namespaces take the format of a valid URI.

    Providing you can GUARANTEE that no one else will use the same thing (and this is done my registering a domain that you control), nothing else matters...

    There is Nothing To "Find"....

    There is NO "info"...

    There is NO "storage".....
    TheCPUWizard is a registered trademark, all rights reserved. (If this post was helpful, please RATE it!)
    2008, 2009,2010
    In theory, there is no difference between theory and practice; in practice there is.

    * Join the fight, refuse to respond to posts that contain code outside of [code] ... [/code] tags. See here for instructions
    * How NOT to post a question here
    * Of course you read this carefully before you posted
    * Need homework help? Read this first

  5. #5
    Join Date
    Oct 2006
    Posts
    123

    Re: give me some declaration about namespace

    May Allah Guide You.Thanks.

  6. #6
    Join Date
    Mar 2002
    Location
    St. Petersburg, Florida, USA
    Posts
    12,116

    Re: give me some declaration about namespace

    Quote Originally Posted by honeyboy_20 View Post
    May Allah Guide You.Thanks.
    Glad to help. Just remember to mark theads as resolved (under the Thread Tools Menu) and to Rate people who spend time helping [using the little scales to the right of the replies]
    TheCPUWizard is a registered trademark, all rights reserved. (If this post was helpful, please RATE it!)
    2008, 2009,2010
    In theory, there is no difference between theory and practice; in practice there is.

    * Join the fight, refuse to respond to posts that contain code outside of [code] ... [/code] tags. See here for instructions
    * How NOT to post a question here
    * Of course you read this carefully before you posted
    * Need homework help? Read this first

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width




On-Demand Webinars (sponsored)