Example #1
0
 public void putAll(ByteArrayToArcMap source)
 {
     foreach (byte[] bytes in source.keySet())
     {
         Arc value = source.get(bytes);
         this.map[new ByteArrayWrapper(bytes)] = value;
     }
 }
Example #2
0
        /**
         * Node constructor<p>
         * @param id : the node unique id. NOTE the id field is unique only in persisted nodes (committed nodes )
         * @param lock : node lock state (true or false ).
         * @param sessionId : local schema sessionId ( needed to avoid, mixing nodes between schemas );
         * @param ownerId :lock owner session id.
         * @param attributesArray : the nodes attributes
         */
        public Node(int id, bool lockEntity, int sessionId,int ownerIdNumber,params NodeAttribute[] attributesArray)
        {
            this.id = id;
            this.lockEntity=lockEntity;
            this.sessionId = sessionId;
            this.ownerId=ownerIdNumber;
            phantom=false;
            children = new ByteArrayToArcMap();
            parents=new CopyOnWriteArrayList<Arc>();
            attributes = new ByteArrayToAttributeyMap();

            foreach (NodeAttribute attribute in attributesArray) {
            attributes.put(attribute.getName(),attribute);
            }
        }