Get an object from this index

@param objectID             the unique identifier of the object to retrieve
@param attributesToRetrieve contains the list of attributes to retrieve.
546146
public JSONObject getObject(String objectID, List<String> attributesToRetrieve) throws AlgoliaException {
    return this.getObject(objectID, attributesToRetrieve, RequestOptions.empty);
  }
51821
@Beta
    public MSICredentials withObjectId(String objectId) {
        this.objectId = objectId;
        this.clientId = null;
        this.identityId = null;
        return this;
    }
656404
private BasicDBObject identifyFieldsToRetrieve(Class<T> entityClass, String viewOfClassName) {
        if (viewOfClassName == null) {
            return null;     // Null is equivalent to retrieving all fields
        }

        BasicDBObject fields = new BasicDBObject();

        try {
            determineFieldsToRetrieve(entityClass, Class.forName(viewOfClassName), "", fields);
        } catch (ClassNotFoundException e) {
            throw new RuntimeException(e);
        }

        if (optimisticLockEnabled) {
            fields.put(OPTIMISTIC_LOCK_VERSION_FIELD, 1);
        }
        
        if (accessControlContextProvider != null) {
            fields.put(ACCESS_CONTROL_FIELD, 1);
        }
        
        if (fields.containsField("id")) {
            fields.remove("id"); // Included by default, no need to specify
        } else {
            fields.put(ID_FIELD, 0); // Need to explicitly exclude it
        }

        return fields;
    }
495083
public final ObjectStore getObjectStore(String objectStoreName)
                    throws ObjectManagerException
    {
        if (Tracing.isAnyTracingEnabled() && trace.isEntryEnabled())
            trace.entry(this, cclass
                        , "getObjectStore"
                        , "objectStoreName=" + objectStoreName + "(String)"
                            );

        ObjectStore objectStore = objectManagerState.getObjectStore(objectStoreName);

        if (Tracing.isAnyTracingEnabled() && trace.isEntryEnabled())
            trace.exit(this, cclass
                       , "getObjectStore"
                       , "returns objectStore=" + objectStore + "(ObjectStore)"
                            );
        return objectStore;
    }
1036124
@PostMapping(
      value = "/{entityTypeId}/{id}/{refAttributeName}",
      params = "_method=GET",
      produces = APPLICATION_JSON_VALUE)
  public Object retrieveEntityAttributePost(
      @PathVariable("entityTypeId") String entityTypeId,
      @PathVariable("id") String untypedId,
      @PathVariable("refAttributeName") String refAttributeName,
      @Valid @RequestBody EntityCollectionRequest request) {
    Set<String> attributesSet = toAttributeSet(request.getAttributes());
    Map<String, Set<String>> attributeExpandSet = toExpandMap(request.getExpand());

    return retrieveEntityAttributeInternal(
        entityTypeId, untypedId, refAttributeName, request, attributesSet, attributeExpandSet);
  }
951218
public Object getAttributeValue(ObjectIdentifier oid)
    throws IOException {
        try {
            Object value = getAttribute(oid).getValue();
            return value;
        } catch (NullPointerException ex) {
            throw new IOException("No value found for attribute " + oid);
        }

    }
1369845
@Override
	public Attribute getAttribute(int index) {
		Attribute attribute = attributes.get(index - 1);
		return attribute;
	}
612212
public Object doGetObjectByIdentity(Identity id) throws PersistenceBrokerException
    {
        if (logger.isDebugEnabled()) logger.debug("getObjectByIdentity " + id);

        // check if object is present in ObjectCache:
        Object obj = objectCache.lookup(id);
        // only perform a db lookup if necessary (object not cached yet)
        if (obj == null)
        {
            obj = getDBObject(id);
        }
        else
        {
            ClassDescriptor cld = getClassDescriptor(obj.getClass());
            // if specified in the ClassDescriptor the instance must be refreshed
            if (cld.isAlwaysRefresh())
            {
                refreshInstance(obj, id, cld);
            }
            // now refresh all references
            checkRefreshRelationships(obj, id, cld);
        }

        // Invoke events on PersistenceBrokerAware instances and listeners
        AFTER_LOOKUP_EVENT.setTarget(obj);
        fireBrokerEvent(AFTER_LOOKUP_EVENT);
        AFTER_LOOKUP_EVENT.setTarget(null);

        //logger.info("RETRIEVING object " + obj);
        return obj;
    }
432673
static public function fetchRelatedObjectsID( $objectID, $attributeID, $allRelations)
    {
        if ( !is_array( $allRelations ) || $allRelations === array() )
        {
            $allRelations = array( 'common', 'xml_embed', 'attribute' );
            if ( eZContentObject::isObjectRelationTyped() )
            {
                $allRelations[] = 'xml_link';
            }
        }

        $relatedObjectsTyped = array();
        foreach ( $allRelations as $relationType )
        {
            $relatedObjectsTyped[$relationType] =
                eZContentFunctionCollection::fetchRelatedObjects( $objectID, $attributeID, array( $relationType ), false, array() );
        }

        $relatedObjectsTypedIDArray = array();
        foreach ( $relatedObjectsTyped as $relationTypeName => $relatedObjectsByType )
        {
            $relatedObjectsTypedIDArray[$relationTypeName] = array();
            foreach ( $relatedObjectsByType['result'] as $relatedObjectByType )
            {
                $relatedObjectsTypedIDArray[$relationTypeName][] = $relatedObjectByType->ID;
            }
        }

        return array( 'result' => $relatedObjectsTypedIDArray );
    }
784257
public Integer getIntObject(String attributeName) {
        String val = get(attributeName, null);
        if (val != null) {
            return Integer.valueOf(val);
        }
        return null;
    }
550594
public void tstore(String name) throws IOException
    {
        TypeMirror cn = getLocalType(name);
        int index = getLocalVariableIndex(name);
        if (Typ.isPrimitive(cn))
        {
            tstore(cn, index);
        }
        else
        {
            astore(index);
        }
    }
460166
@SuppressWarnings("unchecked")
  protected <T> T get(DBIDRef id, int index) {
    return (T) data[idmap.mapDBIDToOffset(id)][index];
  }
403851
public JSONObject getObjects(List<String> objectIDs, List<String> attributesToRetrieve, RequestOptions requestOptions) throws AlgoliaException {
    try {
      JSONArray requests = new JSONArray();
      for (String id : objectIDs) {
        JSONObject request = new JSONObject();
        request.put("indexName", this.indexName);
        request.put("objectID", id);
        request.put("attributesToRetrieve", encodeAttributes(attributesToRetrieve, false));
        requests.put(request);
      }
      JSONObject body = new JSONObject();
      body.put("requests", requests);
      return client.postRequest("/1/indexes/*/objects", body.toString(), false, false, requestOptions);
    } catch (JSONException e) {
      throw new AlgoliaException(e.getMessage());
    } catch (UnsupportedEncodingException e) {
      throw new AlgoliaException(e.getMessage());
    }
  }
428122
public Object getByIdOrFail(final UUID id) throws ObjectToIdMappingException {
        Optional<Object> object = getById(id);
        if (!object.isPresent()) {
            throw new ObjectToIdMappingException(format(
                    "An object with the id [%s] was expected to be known but it was not.  %s", id.toString(),
                    SYNCRONISM_LOST));
        }
        return object.get();
    }
1169671
public Object getObjectWithId( IdKey id ) {
        if ( null != idToObject ) {
            return idToObject.get( id );
        }
        return null;
    }
492187
static function fetchByObjectAttributeID( $id, $contentobjectAttributeID, $asObject = true )
    {
        return eZPersistentObject::fetchObject( eZInformationCollectionAttribute::definition(),
                                                null,
                                                array( 'informationcollection_id' => $id,
                                                       'contentobject_attribute_id' => $contentobjectAttributeID ),
                                                $asObject );
    }
314234
private Node<K, V> getNodeFromStore(final int nodeid) {
		final int index = nodeid < 0 ? -nodeid : nodeid;
		final ByteBuffer buf = storage.get(index);
		final Node<K, V> node = Node.deserialize(buf, this);
		if (rootIdx == node.id) {
			log.warn(this.getClass().getName() + "::getNodeFromStore(" + nodeid + ") WARN LOADED ROOT NODE");
		}
		storage.release(buf);
		if (enableIOStats) {
			getIOStat(nodeid).incPhysRead();
		}
		return node;
	}