Package org.apache.olingo.odata2.api.edm

Examples of org.apache.olingo.odata2.api.edm.EdmException


      edmEntityType = createEntityType(fqName);
      if (edmEntityType != null) {
        edmEntityTypes.put(fqName, edmEntityType);
      }
    } catch (ODataException e) {
      throw new EdmException(EdmException.COMMON, e);
    }

    return edmEntityType;
  }
View Full Code Here


        aliasToNamespaceInfo = createAliasToNamespaceInfo();
        if (aliasToNamespaceInfo == null) {
          aliasToNamespaceInfo = new HashMap<String, String>();
        }
      } catch (ODataException e) {
        throw new EdmException(EdmException.COMMON, e);
      }
    }
    String namespace = aliasToNamespaceInfo.get(namespaceOrAlias);
    // If not contained in info it must be a namespace
    if (namespace == null) {
View Full Code Here

      edmComplexType = createComplexType(fqName);
      if (edmComplexType != null) {
        edmComplexTypes.put(fqName, edmComplexType);
      }
    } catch (ODataException e) {
      throw new EdmException(EdmException.COMMON, e);
    }

    return edmComplexType;
  }
View Full Code Here

      edmAssociation = createAssociation(fqName);
      if (edmAssociation != null) {
        edmAssociations.put(fqName, edmAssociation);
      }
    } catch (ODataException e) {
      throw new EdmException(EdmException.COMMON, e);
    }

    return edmAssociation;
  }
View Full Code Here

    try {
      if (edmEntitySets == null) {
        edmEntitySets = createEntitySets();
      }
    } catch (ODataException e) {
      throw new EdmException(EdmException.COMMON, e);
    }
    return edmEntitySets;
  }
View Full Code Here

    try {
      if (edmFunctionImports == null) {
        edmFunctionImports = createFunctionImports();
      }
    } catch (ODataException e) {
      throw new EdmException(EdmException.COMMON, e);
    }
    return edmFunctionImports;
  }
View Full Code Here

        for (final PropertyRef keyProperty : entityType.getKey().getKeys()) {
          edmKeyPropertyNames.add(keyProperty.getName());
        }
      } else {
        // Entity Type does not define a key
        throw new EdmException(EdmException.COMMON);
      }
    }

    return edmKeyPropertyNames;
  }
View Full Code Here

          final EdmTyped edmProperty = getProperty(keyPropertyName);
          if (edmProperty != null && edmProperty instanceof EdmProperty) {
            keyProperties.put(keyPropertyName, (EdmProperty) edmProperty);
            edmKeyProperties.add((EdmProperty) edmProperty);
          } else {
            throw new EdmException(EdmException.COMMON);
          }
        }
      }
    }
View Full Code Here

      if (edmType == null) {
        edmType = edm.getEntityType(namespace, typeName.getName());
      }

      if (edmType == null) {
        throw new EdmException(EdmException.COMMON);
      }

    }
    return edmType;
  }
View Full Code Here

  private String getValidatedName(final String name) throws EdmException {
    Matcher matcher = PATTERN_VALID_NAME.matcher(name);
    if (matcher.matches()) {
      return name;
    }
    throw new EdmException(EdmException.COMMON);
  }
View Full Code Here

TOP

Related Classes of org.apache.olingo.odata2.api.edm.EdmException

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.