Java源码示例:com.sun.tools.corba.se.idl.AttributeEntry

示例1
/**
 *
 **/
protected void writeMethodTable ()
{
  // Write the methods hashtable
  stream.println ("  private static java.util.Hashtable _methods = new java.util.Hashtable ();");
  stream.println ("  static");
  stream.println ("  {");

  int count = -1;
  Enumeration e = methodList.elements ();
  while (e.hasMoreElements ())
  {
    MethodEntry method = (MethodEntry)e.nextElement ();
    if (method instanceof AttributeEntry)
    {
      stream.println ("    _methods.put (\"_get_" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
      if (!((AttributeEntry)method).readOnly ())
        stream.println ("    _methods.put (\"_set_" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
    }
    else
      stream.println ("    _methods.put (\"" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
  }
  stream.println ("  }");
  stream.println ();
}
 
示例2
/**
 *
 **/
protected void stub (String className, boolean isAbstract, Hashtable symbolTable, MethodEntry m, PrintWriter stream, int index)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.stub (className, isAbstract, symbolTable, a, stream, index);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.stub (className, isAbstract, symbolTable, a, stream, index + 1);
    clear ();
  }
}
 
示例3
/**
 *
 **/
protected void writeMethodTable ()
{
  // Write the methods hashtable
  stream.println ("  private static java.util.Hashtable _methods = new java.util.Hashtable ();");
  stream.println ("  static");
  stream.println ("  {");

  int count = -1;
  Enumeration e = methodList.elements ();
  while (e.hasMoreElements ())
  {
    MethodEntry method = (MethodEntry)e.nextElement ();
    if (method instanceof AttributeEntry)
    {
      stream.println ("    _methods.put (\"_get_" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
      if (!((AttributeEntry)method).readOnly ())
        stream.println ("    _methods.put (\"_set_" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
    }
    else
      stream.println ("    _methods.put (\"" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
  }
  stream.println ("  }");
  stream.println ();
}
 
示例4
/**
 *
 **/
protected void dispatchSkeleton (Hashtable symbolTable, MethodEntry m, PrintWriter stream, int index)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.dispatchSkeleton (symbolTable, a, stream, index);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.dispatchSkeleton (symbolTable, m, stream, index + 1);
    clear ();
  }
}
 
示例5
/**
 *
 **/
protected void writeMethods ()
{
    int realI = 0;
    for (int i = 0; i < methodList.size (); ++i)
        {
            MethodEntry method = (MethodEntry)methodList.elementAt (i);
            ((MethodGen)method.generator ()).skeleton
                (symbolTable, method, stream, realI);
            if (method instanceof AttributeEntry &&
                !((AttributeEntry)method).readOnly ())
                realI += 2;
            else
                ++realI;
            stream.println ();
        }
}
 
示例6
/**
 * <d62023-klr> Added for 2.4 RTF
 **/
protected void interfaceMethod (Hashtable symbolTable, MethodEntry m, PrintWriter stream)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.interfaceMethod (symbolTable, a, stream);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.interfaceMethod (symbolTable, a, stream);
    clear ();
  }
}
 
示例7
/**
 * <d62023-klr> Added for 2.4 RTF
 **/
protected void abstractMethod (Hashtable symbolTable, MethodEntry m, PrintWriter stream)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.abstractMethod (symbolTable, a, stream);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.abstractMethod (symbolTable, a, stream);
    clear ();
  }
}
 
示例8
/**
 * <d62023-klr> Added for 2.4 RTF
 **/
protected void interfaceMethod (Hashtable symbolTable, MethodEntry m, PrintWriter stream)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.interfaceMethod (symbolTable, a, stream);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.interfaceMethod (symbolTable, a, stream);
    clear ();
  }
}
 
示例9
/**
 *
 **/
protected void interfaceMethod (Hashtable symbolTable, MethodEntry m, PrintWriter stream)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.interfaceMethod (symbolTable, a, stream);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.interfaceMethod (symbolTable, a, stream);
    clear ();
  }
}
 
示例10
/**
 *
 **/
protected void stub (String className, boolean isAbstract, Hashtable symbolTable, MethodEntry m, PrintWriter stream, int index)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.stub (className, isAbstract, symbolTable, a, stream, index);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.stub (className, isAbstract, symbolTable, a, stream, index + 1);
    clear ();
  }
}
 
示例11
/**
 *
 **/
protected void skeleton (Hashtable symbolTable, MethodEntry m, PrintWriter stream, int index)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.skeleton (symbolTable, a, stream, index);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.skeleton (symbolTable, a, stream, index + 1);
    clear ();
  }
}
 
示例12
/**
 *
 **/
protected void dispatchSkeleton (Hashtable symbolTable, MethodEntry m, PrintWriter stream, int index)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.dispatchSkeleton (symbolTable, a, stream, index);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.dispatchSkeleton (symbolTable, m, stream, index + 1);
    clear ();
  }
}
 
示例13
/**
 *
 **/
protected void writeMethodTable ()
{
  // Write the methods hashtable
  stream.println ("  private static java.util.Hashtable _methods = new java.util.Hashtable ();");
  stream.println ("  static");
  stream.println ("  {");

  int count = -1;
  Enumeration e = methodList.elements ();
  while (e.hasMoreElements ())
  {
    MethodEntry method = (MethodEntry)e.nextElement ();
    if (method instanceof AttributeEntry)
    {
      stream.println ("    _methods.put (\"_get_" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
      if (!((AttributeEntry)method).readOnly ())
        stream.println ("    _methods.put (\"_set_" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
    }
    else
      stream.println ("    _methods.put (\"" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
  }
  stream.println ("  }");
  stream.println ();
}
 
示例14
/**
 *
 **/
protected void writeMethods ()
{
    int realI = 0;
    for (int i = 0; i < methodList.size (); ++i)
        {
            MethodEntry method = (MethodEntry)methodList.elementAt (i);
            ((MethodGen)method.generator ()).skeleton
                (symbolTable, method, stream, realI);
            if (method instanceof AttributeEntry &&
                !((AttributeEntry)method).readOnly ())
                realI += 2;
            else
                ++realI;
            stream.println ();
        }
}
 
示例15
/**
 * <d62023-klr> Added for 2.4 RTF
 **/
protected void abstractMethod (Hashtable symbolTable, MethodEntry m, PrintWriter stream)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.abstractMethod (symbolTable, a, stream);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.abstractMethod (symbolTable, a, stream);
    clear ();
  }
}
 
示例16
/**
 * <d62023-klr> Added for 2.4 RTF
 **/
protected void interfaceMethod (Hashtable symbolTable, MethodEntry m, PrintWriter stream)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.interfaceMethod (symbolTable, a, stream);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.interfaceMethod (symbolTable, a, stream);
    clear ();
  }
}
 
示例17
/**
 *
 **/
protected void interfaceMethod (Hashtable symbolTable, MethodEntry m, PrintWriter stream)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.interfaceMethod (symbolTable, a, stream);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.interfaceMethod (symbolTable, a, stream);
    clear ();
  }
}
 
示例18
/**
 *
 **/
protected void stub (String className, boolean isAbstract, Hashtable symbolTable, MethodEntry m, PrintWriter stream, int index)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.stub (className, isAbstract, symbolTable, a, stream, index);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.stub (className, isAbstract, symbolTable, a, stream, index + 1);
    clear ();
  }
}
 
示例19
/**
 *
 **/
protected void skeleton (Hashtable symbolTable, MethodEntry m, PrintWriter stream, int index)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.skeleton (symbolTable, a, stream, index);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.skeleton (symbolTable, a, stream, index + 1);
    clear ();
  }
}
 
示例20
/**
 *
 **/
protected void dispatchSkeleton (Hashtable symbolTable, MethodEntry m, PrintWriter stream, int index)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.dispatchSkeleton (symbolTable, a, stream, index);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.dispatchSkeleton (symbolTable, m, stream, index + 1);
    clear ();
  }
}
 
示例21
/**
 *
 **/
protected void writeMethodTable ()
{
  // Write the methods hashtable
  stream.println ("  private static java.util.Hashtable _methods = new java.util.Hashtable ();");
  stream.println ("  static");
  stream.println ("  {");

  int count = -1;
  Enumeration e = methodList.elements ();
  while (e.hasMoreElements ())
  {
    MethodEntry method = (MethodEntry)e.nextElement ();
    if (method instanceof AttributeEntry)
    {
      stream.println ("    _methods.put (\"_get_" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
      if (!((AttributeEntry)method).readOnly ())
        stream.println ("    _methods.put (\"_set_" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
    }
    else
      stream.println ("    _methods.put (\"" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
  }
  stream.println ("  }");
  stream.println ();
}
 
示例22
/**
 *
 **/
protected void writeMethods ()
{
    int realI = 0;
    for (int i = 0; i < methodList.size (); ++i)
        {
            MethodEntry method = (MethodEntry)methodList.elementAt (i);
            ((MethodGen)method.generator ()).skeleton
                (symbolTable, method, stream, realI);
            if (method instanceof AttributeEntry &&
                !((AttributeEntry)method).readOnly ())
                realI += 2;
            else
                ++realI;
            stream.println ();
        }
}
 
示例23
/**
 * <d62023-klr> Added for 2.4 RTF
 **/
protected void abstractMethod (Hashtable symbolTable, MethodEntry m, PrintWriter stream)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.abstractMethod (symbolTable, a, stream);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.abstractMethod (symbolTable, a, stream);
    clear ();
  }
}
 
示例24
/**
 * <d62023-klr> Added for 2.4 RTF
 **/
protected void interfaceMethod (Hashtable symbolTable, MethodEntry m, PrintWriter stream)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.interfaceMethod (symbolTable, a, stream);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.interfaceMethod (symbolTable, a, stream);
    clear ();
  }
}
 
示例25
/**
 *
 **/
protected void interfaceMethod (Hashtable symbolTable, MethodEntry m, PrintWriter stream)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.interfaceMethod (symbolTable, a, stream);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.interfaceMethod (symbolTable, a, stream);
    clear ();
  }
}
 
示例26
/**
 *
 **/
protected void stub (String className, boolean isAbstract, Hashtable symbolTable, MethodEntry m, PrintWriter stream, int index)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.stub (className, isAbstract, symbolTable, a, stream, index);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.stub (className, isAbstract, symbolTable, a, stream, index + 1);
    clear ();
  }
}
 
示例27
/**
 *
 **/
protected void skeleton (Hashtable symbolTable, MethodEntry m, PrintWriter stream, int index)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.skeleton (symbolTable, a, stream, index);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.skeleton (symbolTable, a, stream, index + 1);
    clear ();
  }
}
 
示例28
/**
 *
 **/
protected void dispatchSkeleton (Hashtable symbolTable, MethodEntry m, PrintWriter stream, int index)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.dispatchSkeleton (symbolTable, a, stream, index);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.dispatchSkeleton (symbolTable, m, stream, index + 1);
    clear ();
  }
}
 
示例29
/**
 *
 **/
protected void interfaceMethod (Hashtable symbolTable, MethodEntry m, PrintWriter stream)
{
  AttributeEntry a = (AttributeEntry)m;

  // Generate for the get method
  super.interfaceMethod (symbolTable, a, stream);

  // Generate for the set method if the attribute is not readonly
  if (!a.readOnly ())
  {
    setupForSetMethod ();
    super.interfaceMethod (symbolTable, a, stream);
    clear ();
  }
}
 
示例30
/**
 *
 **/
protected void writeMethodTable ()
{
  // Write the methods hashtable
  stream.println ("  private static java.util.Hashtable _methods = new java.util.Hashtable ();");
  stream.println ("  static");
  stream.println ("  {");

  int count = -1;
  Enumeration e = methodList.elements ();
  while (e.hasMoreElements ())
  {
    MethodEntry method = (MethodEntry)e.nextElement ();
    if (method instanceof AttributeEntry)
    {
      stream.println ("    _methods.put (\"_get_" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
      if (!((AttributeEntry)method).readOnly ())
        stream.println ("    _methods.put (\"_set_" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
    }
    else
      stream.println ("    _methods.put (\"" + Util.stripLeadingUnderscores (method.name ()) + "\", new java.lang.Integer (" + (++count) + "));");
  }
  stream.println ("  }");
  stream.println ();
}