Creates a complete key using the given parameters.

@param parent
the parent key, may be <code>null</code>.
@param id
the numeric ID
517090
private void createCompleteKey(Key parent, long id) {
    String kind = entityMetadata.getKind();
    if (parent == null) {
      key = entityManager.newNativeKeyFactory().setKind(kind).newKey(id);
    } else {
      key = Key.newBuilder(parent, kind, id).build();
    }
  }
492447
function(id) {
            var uploadDataEntry = this.getUploads({id: id}),
                parentId = null;

            if (uploadDataEntry) {
                if (uploadDataEntry.parentId !== undefined) {
                    parentId = uploadDataEntry.parentId;
                }
            }

            return parentId;
        }
1246415
public <E> void delete(Class<E> entityClass, DatastoreKey parentKey, long id) {
    try {
      EntityMetadata entityMetadata = EntityIntrospector.introspect(entityClass);
      Key nativeKey = Key.newBuilder(parentKey.nativeKey(), entityMetadata.getKind(), id).build();
      nativeWriter.delete(nativeKey);
    } catch (DatastoreException exp) {
      throw DatastoreUtils.wrap(exp);
    }
  }
531732
public static String parentResourceIdFromResourceId(String id) {
        if (id == null) {
            return null;
        }
        ResourceId resourceId = ResourceId.fromString(id);
        if (resourceId != null && resourceId.parent() != null) {
            return ResourceId.fromString(id).parent().id();
        }

        return null;
    }
1179297
public void setParent( IVarDef parent)
    {
    parent_ = parent;
    pathName_ = null;
    effCondition_ = null;
    position_ = null;
    }
297320
private void createIncompleteKey(Key parent) {
    String kind = entityMetadata.getKind();
    if (parent == null) {
      key = entityManager.newNativeKeyFactory().setKind(kind).newKey();
    } else {
      key = IncompleteKey.newBuilder(parent, kind).build();
    }
  }
1068658
@Override
    public void setID(String id) {
        _ID = id;
        if (_store != null) {
            _store.setID(id);
        }
    }
812507
public void setParents(java.util.Collection<Parent> parents) {
        if (parents == null) {
            this.parents = null;
            return;
        }

        this.parents = new java.util.ArrayList<Parent>(parents);
    }
397041
private int ascertainParentFingerprint(DeterministicKey parentKey, int parentFingerprint)
    throws IllegalArgumentException {
        if (parentFingerprint != 0) {
            if (parent != null)
                checkArgument(parent.getFingerprint() == parentFingerprint,
                              "parent fingerprint mismatch",
                              Integer.toHexString(parent.getFingerprint()), Integer.toHexString(parentFingerprint));
            return parentFingerprint;
        } else return 0;
    }
279726
public void init(Object parent, Object record)
    {
        super.init(parent, record);
        if (record instanceof FieldList)
            this.addFieldList((FieldList)record, 0);
        else
            this.addFieldList(this.buildFieldList(), 0);
        if (this.getFieldList() != null)
        {
            boolean bAddCache = true;
            if (this instanceof JScreen)
                bAddCache = false;
            this.getBaseApplet().linkNewRemoteTable(this.getFieldList(), bAddCache);
            if (this.getFieldList().getTable() != null)
            {
                if (this.getFieldList().getEditMode() == Constants.EDIT_NONE)
                {
                    try   {
                        this.getFieldList().getTable().addNew();
                    } catch (DBException ex)    {
                        ex.printStackTrace(); // Never.
                    }
                }
            }
        }
    }
893030
public void setId(String id) {
        logger.entering(id);
        this.id = id;
        logger.exiting();
    }
869466
def parent(self, key):
        """"""
        parent_key = '.'.join(key.split('.')[:-1])
        if not parent_key:
            return None
        else:
            return self[parent_key]
905962
public QueryBuilder addParentIds(final Collection<Integer> ids) {
        if (ids != null) {
            parentIds.addAll(ids);
        }
        return this;
    }
1096075
private function ensureParentAndKey($parent, $key)
    {
        if (!$this->parent)
        {
            $this->parent = $parent;
        }
        if (!$this->key)
        {
            $this->key = $key;
        }
        if ($this->parent != $parent)
        {
            throw new \Exception('Internal Error. Relation retrieved from two different Objects.');
        }
        if ($this->key != $key)
        {
            throw new \Exception('Internal Error. Relation retrieved from two different keys.');
        }
    }
72046
public static UIComponent findChild(UIComponent parent, String id)
    {
        int childCount = parent.getChildCount();
        if (childCount > 0)
        {
            for (int i = 0; i < childCount; i++)
            {
                UIComponent child = parent.getChildren().get(i);
                if (id.equals(child.getId()))
                {
                    return child;
                }
            }
        }
        return null;
    }
524496
private void updateParentsFree(int id) {
        int logChild = depth(id) + 1;
        while (id > 1) {
            int parentId = id >>> 1;
            byte val1 = value(id);
            byte val2 = value(id ^ 1);
            logChild -= 1; // in first iteration equals log, subsequently reduce 1 from logChild as we traverse up

            if (val1 == logChild && val2 == logChild) {
                setValue(parentId, (byte) (logChild - 1));
            } else {
                byte val = val1 < val2 ? val1 : val2;
                setValue(parentId, val);
            }

            id = parentId;
        }
    }
777957
final void init(WSJdbcObject parent) {
        if (parent != null) {
            parentWrapper = parent;
            dsConfig = parent.dsConfig; 
            freeResourcesOnClose = parent.freeResourcesOnClose;
        }

        if (freeResourcesOnClose) // then initialize data structures to track them
        {
            arrays = new LinkedList<Array>();
            blobs = new LinkedList<Blob>();
            clobs = new LinkedList<Clob>();
            resources = new LinkedList<Closeable>();
            xmls = new LinkedList<SQLXML>();
        }
    }