コード例 #1
0
 public void fixNullOutputsForSOAP(ConversionEnter_Properties fromClient) {
   // Transform null to "null"
   Class c = fromClient.getClass();
   java.beans.BeanInfo beanInfo = null;
   try {
     beanInfo = java.beans.Introspector.getBeanInfo(c);
   } catch (Exception e) {
   }
   java.beans.PropertyDescriptor[] properties = beanInfo.getPropertyDescriptors();
   for (int i = 0; i < properties.length; i++) {
     java.beans.PropertyDescriptor property = properties[i];
     java.lang.reflect.Method readMethod = property.getReadMethod();
     java.lang.reflect.Method writeMethod = property.getWriteMethod();
     if ((readMethod != null) && (writeMethod != null)) {
       String currentvalue = new String("");
       if (readMethod.getReturnType() == currentvalue.getClass()) {
         try {
           currentvalue = (String) (readMethod.invoke(fromClient, null));
         } catch (java.lang.reflect.InvocationTargetException a1) // Null argument
         {
           try {
             Object[] args1 = new Object[1];
             args1[0] = new String("null");
             writeMethod.invoke(fromClient, args1);
           } catch (Exception e2) {
           }
         } catch (Exception e1) {
         }
       } else {
       }
     }
   }
 }
コード例 #2
0
 public void fixNullInputsForSOAP(ConversionEnter_Properties fromClient) {
   // Transform "null" to null
   Class c = fromClient.getClass();
   java.beans.BeanInfo beanInfo = null;
   try {
     beanInfo = java.beans.Introspector.getBeanInfo(c);
   } catch (Exception e) {
   }
   java.beans.PropertyDescriptor[] properties = beanInfo.getPropertyDescriptors();
   for (int i = 0; i < properties.length; i++) {
     java.beans.PropertyDescriptor property = properties[i];
     java.lang.reflect.Method readMethod = property.getReadMethod();
     java.lang.reflect.Method writeMethod = property.getWriteMethod();
     if ((readMethod != null) && (writeMethod != null)) {
       String currentvalue = new String("");
       if (readMethod.getReturnType() == currentvalue.getClass()) {
         try {
           currentvalue = (String) readMethod.invoke(fromClient, null);
         } catch (Exception e1) {
         }
         if (currentvalue != null) {
           if (currentvalue.equals("null")) {
             try {
               Object[] args1 = new Object[1];
               args1[0] = null;
               writeMethod.invoke(fromClient, args1);
             } catch (Exception e2) {
             }
           }
           if ((currentvalue.length() < 1)
               && (writeMethod.getName().indexOf("PubStartPoolName") > -1)) {
             try {
               Object[] args1 = new Object[1];
               args1[0] = "ICONEJB/null";
               writeMethod.invoke(fromClient, args1);
             } catch (Exception e2) {
             }
           }
           if ((currentvalue.length() < 1) && (writeMethod.getName().indexOf("PubLinkKey") > -1)) {
             try {
               Object[] args1 = new Object[1];
               args1[0] = null;
               writeMethod.invoke(fromClient, args1);
             } catch (Exception e2) {
             }
           }
         }
       } else {
       }
     }
   }
 }
コード例 #3
0
  public ConversionEnter_Properties processIORequest() throws BeanException {
    ConversionEnter_Properties toClient = new ConversionEnter_Properties();

    if ((styleSheet != null) && (styleSheet.length() > 0)) {
      try {
        String xmlData = getHPubXMLProperties(styleSheet);
        toClient.setHPubXMLData(xmlData);

      } catch (Exception e) {
        e.printStackTrace(System.err);
      }
    } else this.processRequest();

    try {
      toClient.setHPubMacroMessage(this.getHPubMacroMessage());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubEndChainName(this.getHPubEndChainName());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubErrorOccurred(this.getHPubErrorOccurred());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubScreenState(this.getHPubScreenState());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubErrorMessage(this.getHPubErrorMessage());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubOutputParmSuffix(this.getHPubOutputParmSuffix());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubStartChainName(this.getHPubStartChainName());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubXMLPropertiesWithoutInvoking(this.getHPubXMLPropertiesWithoutInvoking());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubConnectionOverrides(this.getHPubConnectionOverrides());
    } catch (Exception e) {
    }

    try {
      toClient.setReturnMessage(this.getReturnMessage());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubStartType(this.getHPubStartType());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubLinkKey(this.getHPubLinkKey());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubStartPoolName(this.getHPubStartPoolName());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubBeanType(this.getHPubBeanType());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubEndType(this.getHPubEndType());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubErrorException(this.getHPubErrorException());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubBeanName(this.getHPubBeanName());
    } catch (Exception e) {
    }

    try {
      toClient.setHPubXMLProperties(this.getHPubXMLProperties());
    } catch (Exception e) {
    }

    return toClient;
  }
コード例 #4
0
  public void setVariables(ConversionEnter_Properties fromClient) {
    int tempInt = 0;
    String tempString = null;

    try {
      tempString = fromClient.getHPubMacroMessage();
      this.setHPubMacroMessage(tempString);
    } catch (Exception e) {
    }

    try {
      tempString = fromClient.getHPubEndChainName();
      this.setHPubEndChainName(tempString);
    } catch (Exception e) {
    }

    try {
      tempString = fromClient.getHPubScreenState();
      this.setHPubScreenState(tempString);
    } catch (Exception e) {
    }

    try {
      tempString = fromClient.getHPubStartChainName();
      this.setHPubStartChainName(tempString);
    } catch (Exception e) {
    }

    try {
      tempString = fromClient.getHPubConnectionOverrides();
      this.setHPubConnectionOverrides(tempString);
    } catch (Exception e) {
    }

    try {
      tempInt = fromClient.getHPubStartType();
      this.setHPubStartType(tempInt);
    } catch (Exception e) {
    }

    try {
      tempString = fromClient.getHPubLinkKey();
      this.setHPubLinkKey(tempString);
    } catch (Exception e) {
    }

    try {
      tempString = fromClient.getHPubStartPoolName();
      this.setHPubStartPoolName(tempString);
    } catch (Exception e) {
    }

    try {
      tempInt = fromClient.getHPubEndType();
      this.setHPubEndType(tempInt);
    } catch (Exception e) {
    }

    try {
      styleSheet = fromClient.getHPubStyleSheet();
    } catch (Exception e) {
    }
  }