congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
Import
Code IndexAdd Tabnine to your IDE (free)

How to use
Import
in
com.ebmwebsourcing.easybpmn.bpmn20.api.element

Best Java code snippets using com.ebmwebsourcing.easybpmn.bpmn20.api.element.Import (Showing top 5 results out of 315)

origin: com.ebmwebsourcing.easybpmn/bpmn20-impl

private Element doFindImportedElement(QName eltQName,Set<XmlObject> visited) throws BPMNException {
  for(Import i : getImports()){
    XmlObject content = i.getImportContent();
    if(visited.contains(content)) {
      continue;
      visited.add(content);
    if(i.isXSDImport()){
      Element e = SchemaHelper.findElementByQName(i.getSchema(), eltQName);
      if(e!=null){
        return e;
    else if(i.isWSDL11Import()){
      Element e = SchemaHelper.findElementByQName(i.getWSDL11Definitions(), eltQName);
      if(e!=null){
        return e;
    else if(i.isBPMN20Import()){
      Element e = i.getBPMNDefinitions().findImportedElement(eltQName);
      if(e!=null){
        return e;
origin: com.ebmwebsourcing.easybpmn/bpmn20-impl

@Override
public Import getImport(String namespace) {
  for(Import i : getImports()) {
    if(i.hasNamespace() && i.getNamespace().equals(namespace)) {
      return i;
    }
  }
  return null;
}
origin: com.ebmwebsourcing.petalsbpm/petalsbpm-service

Map<String,String> prefixes = defs.findImportPrefixes(); 
for(Import impt : imports){
  String prefix = prefixes.get(impt.getNamespace());
  ImportBean importBean;
  if(impt.isXSDImport()){
    importBean = ImportAdapter.adaptSchemaImport(prefix, impt.getLocation(), impt.getSchema());
  else if(impt.isWSDL11Import()) {
    importBean = ImportAdapter.adaptWSDLImport(prefix, impt.getLocation(), impt.getWSDL11Definitions());
  else if(impt.isBPMN20Import()) {
    importBean = ImportAdapter.adaptBPMNImport(prefix, impt.getLocation(), impt.getBPMNDefinitions());
    NamespaceDeclaration nsd = new NamespaceDeclaration(null, impt.getNamespace());
    importBean = new ImportBean(nsd);
    importBean.setLocation(impt.getLocation().toString());
    importBean.setImportType(impt.getImportType().toString());
origin: com.ebmwebsourcing.easybpmn/bpmn20-api

/**
 * Searches for a BPMN element in the given Definitions and its BPMN 2.0 imports
 * @param <T>
 * @param defs
 * @param ref Id or {import namespace}Id
 * @param wantedClass
 * @return
 * @throws BPMNException
 */
public static <T extends BaseElement> T findBPMNObject(Definitions defs, QName ref,
    Class<T> wantedClass) throws BPMNException {
  if(ref!=null) {
    if(ref.getNamespaceURI()==null || ref.getNamespaceURI().isEmpty()) {
      return findObjectInDefinitions(defs, ref.getLocalPart(), wantedClass);
    }
    Import impt = defs.getImport(ref.getNamespaceURI());
    if(impt!=null && impt.isBPMN20Import()) {
      Definitions importedDefs = impt.getBPMNDefinitions();
      return findObjectInDefinitions(importedDefs, ref.getLocalPart(), wantedClass);
    }
  }
  throw new BPMNException("No bpmn element has been found for this QName : "+ref);
}
origin: com.ebmwebsourcing.easybpmn/bpmn20-impl

@Override
public Map<String,String> findImportPrefixes() {
  Map<String,String> result = new HashMap<String, String>();
  if(hasImport()) {
    Node defsNode = getXmlObjectDOMNode();
    for(int i=0; i<defsNode.getAttributes().getLength(); i++) {
      Attr attr = (Attr) defsNode.getAttributes().item(i);
      if(attr.getName().startsWith("xmlns:")) {
        Import impt = getImport(attr.getValue());
        if(impt!=null) {
          String prefix = attr.getName().replace("xmlns:", "");
          result.put(impt.getNamespace(), prefix);
        }
      }
    }
  }
  return result;
}
com.ebmwebsourcing.easybpmn.bpmn20.api.elementImport

Most used methods

  • getBPMNDefinitions
  • isBPMN20Import
  • getNamespace
  • getSchema
  • getWSDL11Definitions
  • isWSDL11Import
  • isXSDImport
  • getImportContent
  • getImportType
  • getLocation
  • hasNamespace
  • setImportType
  • hasNamespace,
  • setImportType,
  • setLocation,
  • setNamespace

Popular in Java

  • Reactive rest calls using spring rest template
  • getSharedPreferences (Context)
  • getContentResolver (Context)
  • getExternalFilesDir (Context)
  • Color (java.awt)
    The Color class is used to encapsulate colors in the default sRGB color space or colors in arbitrary
  • FileReader (java.io)
    A specialized Reader that reads from a file in the file system. All read requests made by calling me
  • SecureRandom (java.security)
    This class generates cryptographically secure pseudo-random numbers. It is best to invoke SecureRand
  • ExecutorService (java.util.concurrent)
    An Executor that provides methods to manage termination and methods that can produce a Future for tr
  • IsNull (org.hamcrest.core)
    Is the value null?
  • Logger (org.slf4j)
    The org.slf4j.Logger interface is the main user entry point of SLF4J API. It is expected that loggin
  • Top Vim plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now