Package com.jgaap.generics

Examples of com.jgaap.generics.Canonicizer


   
    return builder.build();
  }
 
  public static Canonicizer getCanonicizer(String action) throws Exception{
    Canonicizer canonicizer;
    String[] tmp = action.split("\\|", 2);
    action = tmp[0].trim().toLowerCase();
    if(canonicizers.containsKey(action)){
      canonicizer = canonicizers.get(action).getClass().newInstance();
    }else{
      throw new Exception("Canonicizer "+action+" not found!");
    }
    if(tmp.length > 1){
      canonicizer.setParameters(tmp[1]);
    }
    return canonicizer;
  }
View Full Code Here


   * @param action - the unique string name representing a canonicizer (displayName())
   * @return - a reference to the canonicizer added
   * @throws Exception - if the canonicizer specified cannot be found or instanced
   */
  public Canonicizer addCanonicizer(String action) throws Exception {
    Canonicizer canonicizer = Canonicizers.getCanonicizer(action);
    for (Document document : documents) {
      addCanonicizer(canonicizer, document);
    }
    return canonicizer;
  }
View Full Code Here

   * @param docType - The DocType this canonicizer is restricted to
   * @return - a reference to the canonicizer added
   * @throws Exception - if the canonicizer specified cannot be found or instanced
   */
  public Canonicizer addCanonicizer(String action, Document.Type docType) throws Exception {
    Canonicizer canonicizer = Canonicizers.getCanonicizer(action);
    for (Document document : documents) {
      if (document.getDocType().equals(docType)) {
        addCanonicizer(canonicizer, document);
      }
    }
View Full Code Here

   * @return - a reference to the canonicizer added
   * @throws Exception - if the canonicizer specified cannot be found or instanced
   */
  public Canonicizer addCanonicizer(String action, Document document)
      throws Exception {
    Canonicizer canonicizer = Canonicizers.getCanonicizer(action);
    return addCanonicizer(canonicizer, document);
  }
View Full Code Here

    logger.info("Adding Canonicizer "+canonicizer.displayName()+" to Document "+document.toString());
    return canonicizer;
  }
 
  public Canonicizer addCanonicizer(String action, EventDriver eventDriver) throws Exception {
    Canonicizer canonicizer = Canonicizers.getCanonicizer(action);
    return addCanonicizer(canonicizer, eventDriver);
  }
View Full Code Here

  }// GEN-LAST:event_CanonicizersPanel_AddCanonicizerButtonActionPerformed

  private void AddCanonicizerSelection() {
    try {

      Canonicizer temp = CanonicizerMasterList
          .get(CanonicizersPanel_CanonicizerListBox
              .getSelectedIndex()).getClass().newInstance();
      SelectedCanonicizerList.add(new Pair<Canonicizer, Object>(temp,
          docTypesList.get(CanonicizersPanel_DocTypeComboBox.getSelectedIndex())));
      UpdateSelectedCanonicizerListBox();
View Full Code Here

TOP

Related Classes of com.jgaap.generics.Canonicizer

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.