Demos and Usage of java.lang.Class.toString()


   1: 
   2: public class ExprEqualsNode extends ExprNode
   3: {
   4:         ...
   5: 
   6:         Class typeOne = JavaClassHelper.getBoxedType(this.getChildNodes().get(0).getType());
   7:         ...
   8:         Class typeTwo = JavaClassHelper.getBoxedType(this.getChildNodes().get(1).getType());
   9: 
  10:         ...
  11:             throw new ExprValidationException("Types returned by equals expression cannot be compared for types " +
  12:                     typeOne.toString() + " and " + typeTwo.toString());

View Full Code Here
   1: 
   2: public class ExprRelationalOpNode extends ExprNode
   3: {
   4:         ...
   5: 
   6:         Class typeOne = JavaClassHelper.getBoxedType(this.getChildNodes().get(0).getType());
   7:         ...
   8:         Class typeTwo = JavaClassHelper.getBoxedType(this.getChildNodes().get(1).getType());
   9: 
  10:         ...
  11:             throw new ExprValidationException("Types returned by relational op sub-expression cannot be compared for types " +
  12:                     typeOne.toString() + " and " + typeTwo.toString());

View Full Code Here
   1: 
   2: public class Application
   3:    {
   4:         ...
   5: 
   6:    public static void loadProperties(Class c)
   7:          throws IOException
   8:         ...
   9:       {
  10:       synchronized (Application.class)
  11:          {
  12:         ...
  13:          throw new IOException("No package.properties file found for class: " +
  14:             c.toString());

View Full Code Here
   1: 
   2: class ProxyProp extends PropertySet {
   3:     private static String title = "Proxy properties";
   4:         ...
   5:     static {
   6:     Class     c = null;
   7:     Attribute a = null;
   8:         ...
   9:     try {
  10:         c = Class.forName("org.w3c.jigsaw.proxy.ProxyProp");
  11:     } catch (Exception ex) {
  12:         ...
  13:             props.putValue(CacheFilter.CACHE_DIRECTORY_P,
  14:                        c.toString());

View Full Code Here
   1: 
   2: public class SeqhoundTask implements ProcessorTaskWorker {
   3:     
   4:         ...
   5:         DataThing inputThing = (DataThing)inputMap.get(inputName);
   6:         Class targetClass = (Class)processor.inputTypes.get(inputName);
   7:         Object targetObject = null;
   8:         ...
   9:             else {
  10:             throw new TaskExecutionException("Unable to generate input of type "+targetClass.toString()+" for input name "+inputName);
  11:             }
  12:         ...
  13:             throw new TaskExecutionException("Unable to generate array input of type "+
  14:                              targetClass.toString()+" for input name "+

View Full Code Here
   1: 
   2: public class JposEntryUtility extends Object
   3: {
   4:         ...
   5: 
   6:     public static String shortClassName( Class classObject )
   7:         ...
   8:     { return classObject.toString().substring( classObject.toString().lastIndexOf( "." ) + 1 ); }
   9: 
  10:         ...
  11:     public static boolean validatePropValue( Object propValue, Class propType )

View Full Code Here
   1: 
   2: public class LoginContextDriver {
   3: 
   4:         ...
   5: 
   6:         LoginContextDriver.login(fs, PasswordCredential.class);
   7:     }
   8:         ...
   9:     
  10:     public static void login(Subject subject, Class cls)
  11:         throws LoginException
  12:         ...
  13:                         "Processing login with credentials of type: "+
  14:                         cls.toString());

View Full Code Here
   1: 
   2: public class DefaultGraphModelFileFormatXML {
   3: 
   4:         ...
   5:         } catch (Exception ex2) {
   6:             if (file.toString().toLowerCase().startsWith("http")
   7:         ...
   8:                     || file.toString().toLowerCase().startsWith("ftp")) {
   9:             } else {
  10:         ...
  11:         if (tmp != null)
  12:             graph.setEditable(new Boolean(tmp.toString()).booleanValue());

View Full Code Here
   1: 
   2: class SLPConfig {
   3: 
   4:         ...
   5: 
   6:     public static class SLPProperties extends Properties {
   7: 
   8:         ...
   9:     try {
  10:         Class.forName("com.sun.slp.Defaults");
  11: 
  12:         ...
  13:                        new Object[] {
  14:             loggerClass.toString()}) + "\n";

View Full Code Here
   1: 
   2: public final class Runtime extends AbstractApplicable {
   3: 
   4:         ...
   5:       {
   6:         Class      k       = toClass(o1);
   7:         Applicable thunk   = Cast.toProcedure(o2);
   8:         ...
   9:     case CLASS_Q:
  10:       return Cast.box(o1 instanceof Class);
  11:     case NAME_TO_CLASS:
  12:         ...
  13:       try {
  14:         return Class.forName(buf.toString());

View Full Code Here
   1: 
   2:   private static HashMap<String,Class> primitiveClasses = new HashMap<String,Class>(8);
   3:   static {
   4:         ...
   5: 
   6:   public static Class classForName(String className) throws ClassNotFoundException {
   7:     Class result = primitiveClasses.get(className);
   8:         ...
   9:       reader.close();
  10:       return contents.toString();
  11:     } catch (Exception e) {
  12:         ...
  13:         sb.append("\\E");
  14:         return sb.toString();

View Full Code Here
   1: 
   2:   private static HashMap<String,Class> primitiveClasses = new HashMap<String,Class>(8);
   3:   static {
   4:         ...
   5: 
   6:   public static Class classForName(String className) throws ClassNotFoundException {
   7:     Class result = primitiveClasses.get(className);
   8:         ...
   9:       reader.close();
  10:       return contents.toString();
  11:     } catch (Exception e) {
  12:         ...
  13:         sb.append("\\E");
  14:         return sb.toString();

View Full Code Here
   1: 
   2: public class Class extends Object implements java.io.Serializable
   3: {
   4:         ...
   5: 
   6:   private java.lang.Class realclass = null;
   7: 
   8:         ...
   9: 
  10:       return forName(arrayname.toString());
  11:     }
  12:         ...
  13: 
  14:     return jname.toString();

View Full Code Here