/*
(non-Javadoc)

@see com.redhat.lightblue.client.LightblueClient#metadata(com.redhat.lightblue .client.request.LightblueRequest)
167383
@Override
    public DefaultLightblueMetadataResponse metadata(LightblueMetadataRequest lightblueRequest) throws LightblueParseException, LightblueResponseException, LightblueHttpClientException, LightblueException {
        HttpResponse response = callService(lightblueRequest, configuration.getMetadataServiceURI());
        return new DefaultLightblueMetadataResponse(
                response.getBody(),
                response.getHeaders(),
                mapper);
    }
241518
def __meta_metadata(self, field, key):
        """"""
        mf = ''
        try:
            mf = str([f[key] for f in self.metadata
                     if f['field_name'] == field][0])
        except IndexError:
            print("%s not in metadata field:%s" % (key, field))
            return mf
        else:
            return mf
716451
public static ServiceEndpoint decodeMetadata(String metadata) {
    try {
      return objectMapper.readValue(metadata, ServiceEndpoint.class);
    } catch (IOException e) {
      LOGGER.error("Failed to read metadata: " + e);
      return null;
    }
  }
18744
public org.tensorflow.framework.RunMetadata getMetadata() {
    return metadata_ == null ? org.tensorflow.framework.RunMetadata.getDefaultInstance() : metadata_;
  }
744720
def determine_metadata(self, request, view):
        """"""
        metadata = super(
            DynamicMetadata,
            self).determine_metadata(
            request,
            view)
        metadata['features'] = getattr(view, 'features', [])
        if hasattr(view, 'get_serializer'):
            serializer = view.get_serializer(dynamic=False)
            if hasattr(serializer, 'get_name'):
                metadata['resource_name'] = serializer.get_name()
            if hasattr(serializer, 'get_plural_name'):
                metadata['resource_name_plural'] = serializer.get_plural_name()
        metadata['properties'] = self.get_serializer_info(serializer)
        return metadata
388848
public Metadata registerMetadata(String name, Connector c, File archive)
   {
      Metadata md = new MetadataImpl(name, c, archive);
      metadataRepository.registerMetadata(md);
      return md;
   }
508725
private void updateRequestMetadata() {
        // Take event level metadata, merge with top level metadata
        // event level metadata takes precedence
        try {
            JSONObject metadata = new JSONObject();
            Iterator<String> i = prefHelper_.getRequestMetadata().keys();
            while (i.hasNext()) {
                String k = i.next();
                metadata.put(k, prefHelper_.getRequestMetadata().get(k));
            }
            JSONObject originalMetadata = params_.optJSONObject(Defines.Jsonkey.Metadata.getKey());
            if (originalMetadata != null) {
                Iterator<String> postIter = originalMetadata.keys();
                while (postIter.hasNext()) {
                    String key = postIter.next();
                    // override keys from above
                    metadata.put(key, originalMetadata.get(key));
                }
            }
            // Install metadata need to be send only with Install request
            if ((this instanceof ServerRequestRegisterInstall) && prefHelper_.getInstallMetadata().length() > 0) {
                params_.putOpt(Defines.Jsonkey.InstallMetadata.getKey(), prefHelper_.getInstallMetadata());
            }
            params_.put(Defines.Jsonkey.Metadata.getKey(), metadata);
        } catch (JSONException e) {
           PrefHelper.Debug("Could not merge metadata, ignoring user metadata.");
        }
    }
1066814
public ManagedConnectionMetaData getMetaData() {

        if (TraceComponent.isAnyTracingEnabled() && TRACE.isEntryEnabled()) {
            SibTr.entry(this, TRACE, "getMetaData");
        }

        if (_metaData == null) {

            _metaData = new SibRaMetaData();
        }

        if (TraceComponent.isAnyTracingEnabled() && TRACE.isEntryEnabled()) {
            SibTr.exit(this, TRACE, "getMetaData", _metaData);
        }
        return _metaData;

    }
661801
public static void putServiceUserInterfaceMetadata(final RequestContext requestContext, final Serializable mdui) {
        if (mdui != null) {
            requestContext.getFlowScope().put(PARAMETER_SERVICE_UI_METADATA, mdui);
        }
    }
75655
public void clearMetaData(Object key) {        if (key == this.key) {
            key = null;
            wmmd = null;
            if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                Tr.debug(tc, "MetaData was removed.");
            }
        } else {
        }
    }
227267
public Operation setMetadata(Metadata metadata, OperationOption... options) {
    return compute.setMetadata(getInstanceId(), metadata, options);
  }
341347
public void removeNodeMetaData(Object key) {
        if (key==null) throw new GroovyBugError("Tried to remove meta data with null key "+this+".");
        if (metaDataMap == null) {
            return;
        }
        metaDataMap.remove(key);
    }
756040
function Metadata(resolve, reject, query, options) {
  this.resolve = this._wrapResolveForProfile(resolve);
  this.reject = reject;
  this.query = query; // The query in case we have to build a backtrace
  this.options = options || {};
  this.cursor = false;
}
807548
public static String encodeMetadata(ServiceEndpoint serviceEndpoint) {
    try {
      return objectMapper.writeValueAsString(serviceEndpoint);
    } catch (IOException e) {
      LOGGER.error("Failed to write metadata: " + e);
      throw Exceptions.propagate(e);
    }
  }
1239259
@GetMapping("/sp/metadata")
    public ResponseEntity<String> getFirstServiceProviderMetadata() {
        val saml2Client = builtClients.findClient(SAML2Client.class);
        if (saml2Client != null) {
            return getSaml2ClientServiceProviderMetadataResponseEntity(saml2Client);
        }
        return getNotAcceptableResponseEntity();
    }
877456
public static GetObjectMetadataRequest createGetObjectMetadataRequestFrom(GetObjectRequest getObjectRequest) {
        return new GetObjectMetadataRequest(getObjectRequest.getBucketName(), getObjectRequest.getKey())
                .withVersionId(getObjectRequest.getVersionId())
                .withRequesterPays(getObjectRequest.isRequesterPays())
                .withSSECustomerKey(getObjectRequest.getSSECustomerKey())
                .withPartNumber(getObjectRequest.getPartNumber());
    }
1335300
public ServiceResult<T> addMetadata(String key, Metadata metadata) {
        this.getMetadata().put(key, metadata);
        return this;
    }