Examples of NFCResource


Examples of org.sonatype.nexus.rest.model.NFCResource

  @GET
  public NFCResourceResponse get(Context context, Request request, Response response, Variant variant)
      throws ResourceException
  {
    try {
      NFCResource resource = new NFCResource();

      // check reposes
      if (getRepositoryGroupId(request) != null) {
        for (Repository repository : getRepositoryRegistry()
            .getRepositoryWithFacet(getRepositoryGroupId(request), GroupRepository.class)
            .getMemberRepositories()) {
          NFCRepositoryResource repoNfc = createNFCRepositoryResource(repository);

          resource.addNfcContent(repoNfc);
        }
      }
      else if (getRepositoryId(request) != null) {
        Repository repository = getRepositoryRegistry().getRepository(getRepositoryId(request));

        NFCRepositoryResource repoNfc = createNFCRepositoryResource(repository);

        resource.addNfcContent(repoNfc);
      }

      NFCResourceResponse result = new NFCResourceResponse();

      result.setData(resource);
View Full Code Here

Examples of org.sonatype.nexus.rest.model.NFCResource

    stats2.setHits(1000);
    stats2.setMisses(5000);
    stats2.setSize(44);
    nfcRepoResource2.setNfcStats(stats2);

    NFCResource resource = new NFCResource();
    resource.addNfcContent(nfcRepoResource1);
    resource.addNfcContent(nfcRepoResource2);

    resourceResponse.setData(resource);

    // Excluded because our damn json reader doesn't support parsing long values...very very bad
    // this.marshalUnmarchalThenCompare( resourceResponse );
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.