Package org.apache.juddi.v3.error

Examples of org.apache.juddi.v3.error.InvalidKeyPassedException


      for (String subscriptionKey : subscriptionKeyList) {
       
        org.apache.juddi.model.ClientSubscriptionInfo modelClientSubscriptionInfo =
          em.find(org.apache.juddi.model.ClientSubscriptionInfo.class, subscriptionKey);
        if (modelClientSubscriptionInfo == null) {
          throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.SubscripKeyNotFound", subscriptionKey));
        }
       
        org.apache.juddi.api_v3.ClientSubscriptionInfo apiClientSubscriptionInfo = new org.apache.juddi.api_v3.ClientSubscriptionInfo();
       
        MappingModelToApi.mapClientSubscriptionInfo(modelClientSubscriptionInfo, apiClientSubscriptionInfo);
View Full Code Here


      for (GetSubscriptionResults getSubscriptionResult : body.getGetSubscriptionResultsList()) {
        String subscriptionKey = getSubscriptionResult.getSubscriptionKey();
        org.apache.juddi.model.ClientSubscriptionInfo modelClientSubscriptionInfo =
          em.find(org.apache.juddi.model.ClientSubscriptionInfo.class, subscriptionKey);
        if (modelClientSubscriptionInfo == null) {
          throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.SubscripKeyNotFound", subscriptionKey));
        }
        org.apache.juddi.api_v3.ClientSubscriptionInfo apiClientSubscriptionInfo = new org.apache.juddi.api_v3.ClientSubscriptionInfo();
        MappingModelToApi.mapClientSubscriptionInfo(modelClientSubscriptionInfo, apiClientSubscriptionInfo);
        clientSubscriptionInfoMap.put(apiClientSubscriptionInfo.getSubscriptionKey(),apiClientSubscriptionInfo);
      }
View Full Code Here

                }

                // No null or empty list
                List<String> entityKeyList = body.getBusinessKey();
                if (entityKeyList == null || entityKeyList.size() == 0) {
                        throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.NoKeys"));
                }

                HashSet<String> dupCheck = new HashSet<String>();
                int i = 0;
                for (String entityKey : entityKeyList) {

                        // Per section 4.4: keys must be case-folded
                        entityKey = entityKey.toLowerCase();
                        entityKeyList.set(i, entityKey);

                        boolean inserted = dupCheck.add(entityKey);
                        if (!inserted) {
                                throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.DuplicateKey", entityKey));
                        }

                        i++;
                }
        }
View Full Code Here

                }

                // No null or empty list
                List<String> entityKeyList = body.getServiceKey();
                if (entityKeyList == null || entityKeyList.size() == 0) {
                        throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.NoKeys"));
                }

                HashSet<String> dupCheck = new HashSet<String>();
                int i = 0;
                for (String entityKey : entityKeyList) {

                        // Per section 4.4: keys must be case-folded
                        entityKey = entityKey.toLowerCase();
                        entityKeyList.set(i, entityKey);

                        boolean inserted = dupCheck.add(entityKey);
                        if (!inserted) {
                                throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.DuplicateKey", entityKey));
                        }

                        i++;
                }
        }
View Full Code Here

                }

                // No null or empty list
                List<String> entityKeyList = body.getBindingKey();
                if (entityKeyList == null || entityKeyList.size() == 0) {
                        throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.NoKeys"));
                }

                HashSet<String> dupCheck = new HashSet<String>();
                int i = 0;
                for (String entityKey : entityKeyList) {

                        // Per section 4.4: keys must be case-folded
                        entityKey = entityKey.toLowerCase();
                        entityKeyList.set(i, entityKey);

                        boolean inserted = dupCheck.add(entityKey);
                        if (!inserted) {
                                throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.DuplicateKey", entityKey));
                        }

                        i++;
                }
        }
View Full Code Here

                }

                // No null or empty list
                List<String> entityKeyList = body.getTModelKey();
                if (entityKeyList == null || entityKeyList.size() == 0) {
                        throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.NoKeys"));
                }

                HashSet<String> dupCheck = new HashSet<String>();
                int i = 0;
                for (String entityKey : entityKeyList) {

                        // Per section 4.4: keys must be case-folded
                        entityKey = entityKey.toLowerCase();
                        entityKeyList.set(i, entityKey);

                        boolean inserted = dupCheck.add(entityKey);
                        if (!inserted) {
                                throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.DuplicateKey", entityKey));
                        }

                        i++;
                }
        }
View Full Code Here

                }

                // No null or empty list
                List<String> entityKeyList = body.getEntityKey();
                if (entityKeyList == null || entityKeyList.size() == 0) {
                        throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.NoKeys"));
                }

                HashSet<String> dupCheck = new HashSet<String>();
                int i = 0;
                for (String entityKey : entityKeyList) {

                        // Per section 4.4: keys must be case-folded
                        entityKey = entityKey.toLowerCase();
                        entityKeyList.set(i, entityKey);

                        boolean inserted = dupCheck.add(entityKey);
                        if (!inserted) {
                                throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.DuplicateKey", entityKey));
                        }

                        i++;
                }
        }
View Full Code Here

      throw new FatalErrorException(new ErrorMessage("errors.NullInput"));
   
    // No null or empty list
    List<String> entityKeyList = body.getPublisherId();
    if (entityKeyList == null || entityKeyList.size() == 0)
      throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.NoKeys"));
   
    if (!((Publisher)publisher).isAdmin())
      throw new UserMismatchException(new ErrorMessage("errors.deletepublisher.AdminReqd"));

    HashSet<String> dupCheck = new HashSet<String>();
    for (String entityKey : entityKeyList) {
      boolean inserted = dupCheck.add(entityKey);
      if (!inserted)
        throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.DuplicateKey", entityKey));
     
      Object obj = em.find(org.apache.juddi.model.Publisher.class, entityKey);
      if (obj == null)
        throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.PublisherNotFound", entityKey));
     
    }
  }
View Full Code Here

      throw new FatalErrorException(new ErrorMessage("errors.NullInput"));
   
    // No null or empty list
    List<String> publisherIdList = body.getPublisherId();
    if (publisherIdList == null || publisherIdList.size() == 0)
      throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.NoKeys"));

    HashSet<String> dupCheck = new HashSet<String>();
    for (String publisherId : publisherIdList) {
      boolean inserted = dupCheck.add(publisherId);
      if (!inserted)
        throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.DuplicateKey", publisherId));
    }
  }
View Full Code Here

      throw new FatalErrorException(new ErrorMessage("errors.NullInput"));
   
    // No null or empty list
    List<String> entityKeyList = body.getSubscriptionKey();
    if (entityKeyList == null || entityKeyList.size() == 0)
      throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.NoKeys"));
   
    HashSet<String> dupCheck = new HashSet<String>();
    for (String entityKey : entityKeyList) {
      boolean inserted = dupCheck.add(entityKey);
      if (!inserted)
        throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.DuplicateKey", entityKey));
     
      Object obj = em.find(org.apache.juddi.model.ClientSubscriptionInfo.class, entityKey);
      if (obj == null)
        throw new InvalidKeyPassedException(new ErrorMessage("errors.invalidkey.SubscriptionKeyNotFound", entityKey));
     
    }
  }
View Full Code Here

TOP

Related Classes of org.apache.juddi.v3.error.InvalidKeyPassedException

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.