< prev index next >

src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NamedNodeMapImpl.java

Print this page


   1 /*
   2  * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
   3  * @LastModified: Oct 2017
   4  */
   5 /*
   6  * Licensed to the Apache Software Foundation (ASF) under one or more
   7  * contributor license agreements.  See the NOTICE file distributed with
   8  * this work for additional information regarding copyright ownership.
   9  * The ASF licenses this file to You under the Apache License, Version 2.0
  10  * (the "License"); you may not use this file except in compliance with
  11  * the License.  You may obtain a copy of the License at
  12  *
  13  *      http://www.apache.org/licenses/LICENSE-2.0
  14  *
  15  * Unless required by applicable law or agreed to in writing, software
  16  * distributed under the License is distributed on an "AS IS" BASIS,
  17  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  18  * See the License for the specific language governing permissions and
  19  * limitations under the License.
  20  */
  21 
  22 package com.sun.org.apache.xerces.internal.dom;
  23 


  40  * require more work, such as firing mutation events, they are stored in
  41  * a subclass of NamedNodeMapImpl.
  42  * <P>
  43  * Only one Node may be stored per name; attempting to
  44  * store another will replace the previous value.
  45  * <P>
  46  * NOTE: The "primary" storage key is taken from the NodeName attribute of the
  47  * node. The "secondary" storage key is the namespaceURI and localName, when
  48  * accessed by DOM level 2 nodes. All nodes, even DOM Level 2 nodes are stored
  49  * in a single Vector sorted by the primary "nodename" key.
  50  * <P>
  51  * NOTE: item()'s integer index does _not_ imply that the named nodes
  52  * must be stored in an array; that's only an access method. Note too
  53  * that these indices are "live"; if someone changes the map's
  54  * contents, the indices associated with nodes may change.
  55  * <P>
  56  *
  57  * @xerces.internal
  58  *
  59  * @since  PR-DOM-Level-1-19980818.

  60  */
  61 public class NamedNodeMapImpl
  62     implements NamedNodeMap, Serializable {
  63 
  64     //
  65     // Constants
  66     //
  67 
  68     /** Serialization version. */
  69     static final long serialVersionUID = -7039242451046758020L;
  70 
  71     //
  72     // Data
  73     //
  74 
  75     protected short flags;
  76 
  77     protected final static short READONLY     = 0x1<<0;
  78     protected final static short CHANGED      = 0x1<<1;
  79     protected final static short HASDEFAULTS  = 0x1<<2;


   1 /*
   2  * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.

   3  */
   4 /*
   5  * Licensed to the Apache Software Foundation (ASF) under one or more
   6  * contributor license agreements.  See the NOTICE file distributed with
   7  * this work for additional information regarding copyright ownership.
   8  * The ASF licenses this file to You under the Apache License, Version 2.0
   9  * (the "License"); you may not use this file except in compliance with
  10  * the License.  You may obtain a copy of the License at
  11  *
  12  *      http://www.apache.org/licenses/LICENSE-2.0
  13  *
  14  * Unless required by applicable law or agreed to in writing, software
  15  * distributed under the License is distributed on an "AS IS" BASIS,
  16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  17  * See the License for the specific language governing permissions and
  18  * limitations under the License.
  19  */
  20 
  21 package com.sun.org.apache.xerces.internal.dom;
  22 


  39  * require more work, such as firing mutation events, they are stored in
  40  * a subclass of NamedNodeMapImpl.
  41  * <P>
  42  * Only one Node may be stored per name; attempting to
  43  * store another will replace the previous value.
  44  * <P>
  45  * NOTE: The "primary" storage key is taken from the NodeName attribute of the
  46  * node. The "secondary" storage key is the namespaceURI and localName, when
  47  * accessed by DOM level 2 nodes. All nodes, even DOM Level 2 nodes are stored
  48  * in a single Vector sorted by the primary "nodename" key.
  49  * <P>
  50  * NOTE: item()'s integer index does _not_ imply that the named nodes
  51  * must be stored in an array; that's only an access method. Note too
  52  * that these indices are "live"; if someone changes the map's
  53  * contents, the indices associated with nodes may change.
  54  * <P>
  55  *
  56  * @xerces.internal
  57  *
  58  * @since  PR-DOM-Level-1-19980818.
  59  * @LastModified: Oct 2017
  60  */
  61 public class NamedNodeMapImpl
  62     implements NamedNodeMap, Serializable {
  63 
  64     //
  65     // Constants
  66     //
  67 
  68     /** Serialization version. */
  69     static final long serialVersionUID = -7039242451046758020L;
  70 
  71     //
  72     // Data
  73     //
  74 
  75     protected short flags;
  76 
  77     protected final static short READONLY     = 0x1<<0;
  78     protected final static short CHANGED      = 0x1<<1;
  79     protected final static short HASDEFAULTS  = 0x1<<2;


< prev index next >