agave-metadata/metadata-core/src/main/java/org/iplantc/service/metadata/model/serialization/MetadataItemSerializer.java
/**
     * Format MetadataItem to DBObject with the resolved URLS
     *
     * @return DBObject equivalent of the MetadataItems with the resolved URLS
     * @throws UUIDException
     * @deprecated
     */
Format MetadataItem to DBObject with the resolved URLS
@return DBObject equivalent of the MetadataItems with the resolved URLS
@throws UUIDException
@deprecated
Format MetadataItem to DBObject with the resolved URLS @return DBObject equivalent of the MetadataItems with the resolved URLS @throws UUIDException @deprecated
public DBObject formatMetadataItemResult(MetadataItem metadataItem) throws UUIDException {
        BasicDBObject metadataObject = formatMetadataItem(metadataItem);
        BasicDBObject hal = new BasicDBObject();
        if (resourceURL == null)
            this.resourceURL = TenancyHelper.resolveURLToCurrentTenant(Settings.IPLANT_METADATA_SERVICE);
        hal.put("self",
                new BasicDBObject("href",
                        resourceURL + "data/" +
                                metadataItem.getUuid()));
        hal.put("permissions",
                new BasicDBObject("href",
                        resourceURL + "data/" +
                                metadataItem.getUuid() + "/pems"));
        hal.put("owner",
                new BasicDBObject("href",
                        resourceURL + metadataItem.getOwner()));
        if (metadataItem.getAssociations() != null) {
            BasicDBList halAssociationIds = new BasicDBList();
            MetadataAssociationList associationList = metadataItem.getAssociations();
            halAssociationIds = formatAssociationIds(associationList);
            hal.put("associationIds", halAssociationIds);
        }
        if (metadataItem.getSchemaId() != null && !StringUtils.isEmpty(metadataItem.getSchemaId())) {
            AgaveUUID agaveUUID = new AgaveUUID(metadataItem.getSchemaId());
            hal.append(agaveUUID.getResourceType().name(),
                    new BasicDBObject("href", TenancyHelper.resolveURLToCurrentTenant(agaveUUID.getObjectReference())));
        }
        metadataObject.put("_links", hal);
        return metadataObject;
    }
public DBObject formatMetadataItemResult ( MetadataItem metadataItem ) throws UUIDException { BasicDBObject metadataObject = formatMetadataItem ( metadataItem ) ; BasicDBObject hal = new BasicDBObject ( ) ; if ( resourceURL == null ) this . resourceURL = TenancyHelper . resolveURLToCurrentTenant ( Settings . IPLANT_METADATA_SERVICE ) ; hal . put ( "self" , new BasicDBObject ( "href" , resourceURL + "data/" + metadataItem . getUuid ( ) ) ) ; hal . put ( "permissions" , new BasicDBObject ( "href" , resourceURL + "data/" + metadataItem . getUuid ( ) + "/pems" ) ) ; hal . put ( "owner" , new BasicDBObject ( "href" , resourceURL + metadataItem . getOwner ( ) ) ) ; if ( metadataItem . getAssociations ( ) != null ) { BasicDBList halAssociationIds = new BasicDBList ( ) ; MetadataAssociationList associationList = metadataItem . getAssociations ( ) ; halAssociationIds = formatAssociationIds ( associationList ) ; hal . put ( "associationIds" , halAssociationIds ) ; } if ( metadataItem . getSchemaId ( ) != null && ! StringUtils . isEmpty ( metadataItem . getSchemaId ( ) ) ) { AgaveUUID agaveUUID = new AgaveUUID ( metadataItem . getSchemaId ( ) ) ; hal . append ( agaveUUID . getResourceType ( ) . name ( ) , new BasicDBObject ( "href" , TenancyHelper . resolveURLToCurrentTenant ( agaveUUID . getObjectReference ( ) ) ) ) ; } metadataObject . put ( "_links" , hal ) ; return metadataObject ; }
Format MetadataItem to DBObject with the resolved URLS
 @return DBObject equivalent of the MetadataItems with the resolved URLS
 @throws UUIDException
 @deprecated
Format MetadataItem to DBObject with the resolved URLS @return DBObject equivalent of the MetadataItems with the resolved URLS @throws UUIDException @deprecated