Examples of DataNotFoundException


Examples of com.opengamma.DataNotFoundException

  public OrganizationDocument get(ObjectIdentifiable objectId, VersionCorrection versionCorrection) {
    ArgumentChecker.notNull(objectId, "objectId");
    ArgumentChecker.notNull(versionCorrection, "versionCorrection");
    final OrganizationDocument document = _store.get(objectId.getObjectId());
    if (document == null) {
      throw new DataNotFoundException("Organization not found: " + objectId);
    }
    return cloneOrganizationDocument(document);
  }
View Full Code Here

Examples of com.opengamma.DataNotFoundException

    final UniqueId uniqueId = document.getUniqueId();
    final Instant now = Instant.now();
    final OrganizationDocument storedDocument = _store.get(uniqueId.getObjectId());
    if (storedDocument == null) {
      throw new DataNotFoundException("Organization not found: " + uniqueId);
    }

    final OrganizationDocument clonedDoc = cloneOrganizationDocument(document);

View Full Code Here

Examples of com.opengamma.DataNotFoundException

  @Override
  public void remove(ObjectIdentifiable objectIdentifiable) {
    ArgumentChecker.notNull(objectIdentifiable, "objectIdentifiable");
    OrganizationDocument storedDocument = _store.remove(objectIdentifiable.getObjectId());
    if (storedDocument == null) {
      throw new DataNotFoundException("Organization not found " + objectIdentifiable);
    }   
    _changeManager.entityChanged(ChangeType.REMOVED, objectIdentifiable.getObjectId(), null, null, Instant.now());
  }
View Full Code Here

Examples of com.opengamma.DataNotFoundException

  @Override
  public ManageableOrganization getOrganization(UniqueId organizationId) {
    ArgumentChecker.notNull(organizationId, "organizationId");
    ManageableOrganization organization = _store.get(organizationId.getObjectId()).getOrganization();
    if (organization == null) {
      throw new DataNotFoundException("Organization not found: " + organizationId);
    }
    return cloneOrganization(organization);
  }
View Full Code Here

Examples of com.opengamma.DataNotFoundException

  public RegionDocument get(final ObjectIdentifiable objectId, final VersionCorrection versionCorrection) {
    ArgumentChecker.notNull(objectId, "objectId");
    ArgumentChecker.notNull(versionCorrection, "versionCorrection");
    final RegionDocument document = _store.get(objectId.getObjectId());
    if (document == null) {
      throw new DataNotFoundException("Region not found: " + objectId);
    }
    return document;
  }
View Full Code Here

Examples of com.opengamma.DataNotFoundException

    final UniqueId uniqueId = document.getUniqueId();
    final Instant now = Instant.now();
    final RegionDocument storedDocument = _store.get(uniqueId.getObjectId());
    if (storedDocument == null) {
      throw new DataNotFoundException("Region not found: " + uniqueId);
    }
    document.setVersionFromInstant(now);
    document.setVersionToInstant(null);
    document.setCorrectionFromInstant(now);
    document.setCorrectionToInstant(null);
View Full Code Here

Examples of com.opengamma.DataNotFoundException

  //-------------------------------------------------------------------------
  @Override
  public void remove(final ObjectIdentifiable objectIdentifiable) {
    ArgumentChecker.notNull(objectIdentifiable, "objectIdentifiable");
    if (_store.remove(objectIdentifiable.getObjectId()) == null) {
      throw new DataNotFoundException("Region not found: " + objectIdentifiable);
    }
    _changeManager.entityChanged(ChangeType.REMOVED, objectIdentifiable.getObjectId(), null, null, Instant.now());
  }
View Full Code Here

Examples of exceptions.DataNotFoundException

    if (!partitionLocations.exists() && !partitionLocations.mkdirs()) {

      String msg = "Unable to create location : "
          + partitionLocations.getAbsolutePath();
      logger.severe(msg);
      throw new DataNotFoundException(msg);
    }
    return JPregelConstants.PARTITIONS_LOCATION;
  }
View Full Code Here

Examples of exceptions.DataNotFoundException

      }
    } else {
      if (!solnsLocation.mkdirs()) {
        String msg = "Unable to create location : "
            + solnsLocation.getAbsolutePath();
        throw new DataNotFoundException(msg);
      }
    }
  }
View Full Code Here

Examples of exceptions.DataNotFoundException

    if (!chkPointLocation.exists() && !chkPointLocation.mkdirs()) {

      String msg = "Unable to create location : "
          + chkPointLocation.getAbsolutePath();
      logger.severe(msg);
      throw new DataNotFoundException(msg);
    }
    return chkPointLocation.getAbsolutePath();
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.