Package org.teiid.rhq.plugin.objects

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


  public <T> void getTransactionCollectionValue(MetaValue pValue, Collection<TransactionMetadata> list) throws Exception {
    MetaType metaType = pValue.getMetaType();
    if (metaType.isCollection()) {
      for (MetaValue value : ((CollectionValueSupport) pValue).getElements()) {
        if (value.getMetaType().isComposite()) {
          TransactionMetadata transaction = unwrapTransactionMetaValue(value);
          list.add(transaction);
        } 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;
     
      TransactionMetadata transaction = new TransactionMetadata();
      transaction.setAssociatedSession((String) ProfileServiceUtil.stringValue(compositeValue.get(ASSOCIATED_SESSION)));
      transaction.setCreatedTime((Long) ProfileServiceUtil.longValue(compositeValue.get(CREATED_TIME)));
      transaction.setScope((String) ProfileServiceUtil.stringValue(compositeValue.get(SCOPE)));
      transaction.setId((String) ProfileServiceUtil.stringValue(compositeValue.get("id"))); //$NON-NLS-1$
      return transaction;
    }
    throw new IllegalStateException("Unable to unwrap TransactionMetadata " + metaValue); //$NON-NLS-1$
  }
View Full Code Here

TOP

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

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.