Package org.teiid.rhq.plugin.objects

Examples of org.teiid.rhq.plugin.objects.RequestMetadata


  private void getRequestCollectionValue(MetaValue pValue, Collection<RequestMetadata> list) throws Exception {
    MetaType metaType = pValue.getMetaType();
    if (metaType.isCollection()) {
      for (MetaValue value : ((CollectionValueSupport) pValue).getElements()) {
        if (value.getMetaType().isComposite()) {
          RequestMetadata request = unwrapRequestMetaValue(value);
          list.add(request);
        } else {
          throw new IllegalStateException(pValue + " is not a Composite type"); //$NON-NLS-1$
        }
      }
View Full Code Here


      return null;

    if (metaValue instanceof CompositeValue) {
      CompositeValue compositeValue = (CompositeValue) metaValue;
     
      RequestMetadata request = new RequestMetadata();
      request.setExecutionId((Long) ProfileServiceUtil.longValue(compositeValue.get(EXECUTION_ID)));
      request.setSessionId((String) ProfileServiceUtil.stringValue(compositeValue.get(SESSION_ID)));
      request.setStartTime((Long) ProfileServiceUtil.longValue(compositeValue.get(START_TIME)));
      request.setCommand((String) ProfileServiceUtil.stringValue(compositeValue.get(COMMAND)));
      request.setSourceRequest((Boolean) ProfileServiceUtil.booleanValue(compositeValue.get(SOURCE_REQUEST)));
      request.setNodeId((Integer) ProfileServiceUtil.integerValue(compositeValue.get(NODE_ID)));
      request.setTransactionId((String) ProfileServiceUtil.stringValue(compositeValue.get(TRANSACTION_ID)));
      request.setState((ProcessingState) ProfileServiceUtil.getSimpleValue(compositeValue.get(STATE), ProcessingState.class));
      return request;
    }
    throw new IllegalStateException("Unable to unwrap RequestMetadata " + metaValue); //$NON-NLS-1$
  }
View Full Code Here

TOP

Related Classes of org.teiid.rhq.plugin.objects.RequestMetadata

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.