org.eclipse.jem.proxy_2.0.400.v201101101900

{
            if (!beanProxies.containsKey(typeName)) {
              beanProxies.put(typeName, event.getProxy());
            }
          }
        }
        
        public void proxyNotResolved(ExpressionProxy.ProxyEvent event)
        {
          ((IDEExpression)((ExpressionProxy)event.getSource()).getExpression()).removeBeanType(val$typeName);
        }
      });
    }
  }
  
  public synchronized boolean isBeanTypeRegistered(String className)
  {
    return beanProxies.containsKey(MapTypes.getJNIFormatName(className));
  }
  
  public Set registeredTypes()
  {
    return beanProxies.keySet();
  }
  
  public boolean isBeanTypeNotFound(String className)
  {
    return false;
  }
  
  public boolean isMaintainNotFoundTypes()
  {
    return false;
  }
  
  public void setMaintainNotFoundTypes(boolean maintain) {}
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.IDEStandardBeanTypeProxyFactory
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide;

import org.eclipse.jem.internal.proxy.core.IBeanTypeProxy;
import org.eclipse.jem.internal.proxy.core.IStringBeanProxy;

final class IDEStringBeanProxy
  extends IDEObjectBeanProxy
  implements IStringBeanProxy
{
  protected String fString;
  
  IDEStringBeanProxy(IDEProxyFactoryRegistry aRegistry, Object aBean, IBeanTypeProxy aBeanTypeProxy)
  {
    super(aRegistry, aBean, aBeanTypeProxy);
    fString = ((String)aBean);
  }
  
  public String stringValue()
  {
    return fString;
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.IDEStringBeanProxy
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide;

import org.eclipse.jem.internal.proxy.core.IStringBeanProxy;

final class IDEStringBeanTypeProxy
  extends IDEBeanTypeProxy
{
  protected final IDEStringBeanProxy emptyStringProxy;
  
  IDEStringBeanTypeProxy(IDEProxyFactoryRegistry aRegistry, Class aClass)
  {
    super(aRegistry, aClass);
    
    emptyStringProxy = new IDEStringBeanProxy(aRegistry, "", this);
  }
  
  IStringBeanProxy createStringBeanProxy(String aString)
  {
    if (aString.equals("")) {
      return emptyStringProxy;
    }
    return new IDEStringBeanProxy(fProxyFactoryRegistry, aString, this);
  }
  
  protected IIDEBeanProxy newBeanProxy(Object anObject)
  {
    return (IIDEBeanProxy)createStringBeanProxy((String)anObject);
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.IDEStringBeanTypeProxy
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide;

import java.io.PrintStream;
import java.io.PrintWriter;
import org.eclipse.jem.internal.proxy.core.IBeanProxy;
import org.eclipse.jem.internal.proxy.core.IBeanTypeProxy;
import org.eclipse.jem.internal.proxy.core.ProxyFactoryRegistry;
import org.eclipse.jem.internal.proxy.core.ThrowableProxy;

public class IDEThrowableProxy
  extends ThrowableProxy
  implements IIDEBeanProxy
{
  private static final long serialVersionUID = 7162757961175978338L;
  protected IBeanTypeProxy fBeanTypeProxy;
  
  protected IDEThrowableProxy(Throwable exc, IBeanTypeProxy aBeanTypeProxy)
  {
    super(exc);
    fBeanTypeProxy = aBeanTypeProxy;
  }
  
  public boolean equals(Object obj)
  {
    if (super.equals(obj)) {
      return true;
    }
    if ((obj instanceof IIDEBeanProxy)) {
      return getCause().equals(((IIDEBeanProxy)obj).getBean());
    }
    return false;
  }
  
  public boolean sameAs(IBeanProxy aBeanProxy)
  {
    if (this == aBeanProxy) {
      return true;
    }
    if ((aBeanProxy instanceof IIDEBeanProxy)) {
      return getCause() == ((IIDEBeanProxy)aBeanProxy).getBean();
    }
    return false;
  }
  
  public String getProxyLocalizedMessage()
  {
    return getCause().getLocalizedMessage();
  }
  
  public String getProxyMessage()
  {
    return getCause().getMessage();
  }
  
  public void printProxyStackTrace(PrintWriter writer)
  {
    getCause().printStackTrace(writer);
  }
  
  public void printProxyStackTrace(PrintStream stream)
  {
    getCause().printStackTrace(stream);
  }
  
  public void printProxyStackTrace()
  {
    getCause().printStackTrace();
  }
  
  public IBeanTypeProxy getTypeProxy()
  {
    return fBeanTypeProxy;
  }
  
  public ProxyFactoryRegistry getProxyFactoryRegistry()
  {
    return fBeanTypeProxy.getProxyFactoryRegistry();
  }
  
  public String toBeanString()
  {
    return getCause().toString();
  }
  
  public boolean isValid()
  {
    return true;
  }
  
  public Object getBean()
  {
    return getCause();
  }
  
  public final boolean isBeanProxy()
  {
    return true;
  }
  
  public final boolean isExpressionProxy()
  {
    return false;
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.IDEThrowableProxy
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide;

import org.eclipse.jem.internal.proxy.common.CommandException;
import org.eclipse.jem.internal.proxy.common.ICallbackHandler;
import org.eclipse.jem.internal.proxy.common.ICallbackHandler.TransmitableArray;

class IDEVMServer$1
  implements ICallbackHandler
{
  final IDEVMServer this$0;
  
  IDEVMServer$1(IDEVMServer paramIDEVMServer)
  {
    this$0 = paramIDEVMServer;
  }
  
  public Object callbackWithParms(int callbackID, int msgID, Object[] parms)
  {
    Object[] proxyParms = (Object[])null;
    if (parms != null)
    {
      proxyParms = new Object[parms.length];
      for (int i = 0; i < parms.length; i++)
      {
        Object p = parms[i];
        proxyParms[i] = createNextParm(p);
      }
    }
    return this$0.fCallbackRegistry.vmCallback(callbackID, msgID, proxyParms);
  }
  
  private Object createNextParm(Object p)
  {
    if (!(p instanceof ICallbackHandler.TransmitableArray)) {
      return this$0.fBeanProxyFactory.createIDEBeanProxyWith(p);
    }
    Object[] array = ((ICallbackHandler.TransmitableArray)p).getArray();
    Object[] parm = new Object[array.length];
    for (int i = 0; i < array.length; i++) {
      parm[i] = createNextParm(array[i]);
    }
    return parm;
  }
  
  public Object callbackAsConstants(int callbackID, int msgID, Object parm)
    throws CommandException
  {
    return this$0.fCallbackRegistry.vmCallback(callbackID, msgID, parm);
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.IDEVMServer.1
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide;

import java.io.OutputStream;
import org.eclipse.jem.internal.proxy.common.CommandException;
import org.eclipse.jem.internal.proxy.common.ICallbackHandler;
import org.eclipse.jem.internal.proxy.common.ICallbackHandler.TransmitableArray;
import org.eclipse.jem.internal.proxy.common.ICallbackRunnable;
import org.eclipse.jem.internal.proxy.common.IVMCallbackServer;
import org.eclipse.jem.internal.proxy.common.IVMServer;

public class IDEVMServer
  implements IVMCallbackServer
{
  IDECallbackRegistry fCallbackRegistry;
  IDEStandardBeanProxyFactory fBeanProxyFactory;
  
  IDEVMServer(IDECallbackRegistry aCallbackRegistry)
  {
    fCallbackRegistry = aCallbackRegistry;
    fBeanProxyFactory = ((IDEStandardBeanProxyFactory)fCallbackRegistry.fProxyFactoryRegistry.getBeanProxyFactory());
  }
  
  public Object doCallback(ICallbackRunnable aRunnable)
  {
    try
    {
      aRunnable.run(new ICallbackHandler()
      {
        public Object callbackWithParms(int callbackID, int msgID, Object[] parms)
        {
          Object[] proxyParms = (Object[])null;
          if (parms != null)
          {
            proxyParms = new Object[parms.length];
            for (int i = 0; i < parms.length; i++)
            {
              Object p = parms[i];
              proxyParms[i] = createNextParm(p);
            }
          }
          return fCallbackRegistry.vmCallback(callbackID, msgID, proxyParms);
        }
        
        private Object createNextParm(Object p)
        {
          if (!(p instanceof ICallbackHandler.TransmitableArray)) {
            return fBeanProxyFactory.createIDEBeanProxyWith(p);
          }
          Object[] array = ((ICallbackHandler.TransmitableArray)p).getArray();
          Object[] parm = new Object[array.length];
          for (int i = 0; i < array.length; i++) {
            parm[i] = createNextParm(array[i]);
          }
          return parm;
        }
        
        public Object callbackAsConstants(int callbackID, int msgID, Object parm)
          throws CommandException
        {
          return fCallbackRegistry.vmCallback(callbackID, msgID, parm);
        }
      });
    }
    catch (CommandException localCommandException) {}
    return null;
  }
  
  public OutputStream requestStream(int callbackID, int msgID)
    throws CommandException
  {
    return fCallbackRegistry.requestStream(callbackID, msgID);
  }
  
  public IVMServer getIVMServer()
  {
    return fCallbackRegistry.fProxyFactoryRegistry;
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.IDEVMServer
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide;

import org.eclipse.jem.internal.proxy.core.IBeanProxy;

public abstract interface IIDEBeanProxy
  extends IBeanProxy
{
  public abstract Object getBean();
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.IIDEBeanProxy
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide.awt;

import java.awt.Dimension;
import org.eclipse.jem.internal.proxy.core.IBeanTypeProxy;
import org.eclipse.jem.internal.proxy.core.IDimensionBeanProxy;
import org.eclipse.jem.internal.proxy.ide.IDEObjectBeanProxy;
import org.eclipse.jem.internal.proxy.ide.IDEProxyFactoryRegistry;

public class IDEDimensionBeanProxy
  extends IDEObjectBeanProxy
  implements IDimensionBeanProxy
{
  protected Dimension fDimension;
  
  IDEDimensionBeanProxy(IDEProxyFactoryRegistry aRegistry, Object aDimension, IBeanTypeProxy aBeanTypeProxy)
  {
    super(aRegistry, aDimension, aBeanTypeProxy);
    fDimension = ((Dimension)aDimension);
  }
  
  public int getWidth()
  {
    return fDimension.width;
  }
  
  public void setWidth(int aWidth)
  {
    fDimension.width = aWidth;
  }
  
  public int getHeight()
  {
    return fDimension.height;
  }
  
  public void setHeight(int aHeight)
  {
    fDimension.height = aHeight;
  }
  
  public void setSize(IDimensionBeanProxy aBeanProxy)
  {
    fDimension.setSize(new Dimension(aBeanProxy.getWidth(), aBeanProxy.getHeight()));
  }
  
  public void setSize(int width, int height)
  {
    fDimension.width = width;
    fDimension.height = height;
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.awt.IDEDimensionBeanProxy
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide.awt;

import java.awt.Dimension;
import org.eclipse.jem.internal.proxy.ide.IDEBeanTypeProxy;
import org.eclipse.jem.internal.proxy.ide.IDEProxyFactoryRegistry;
import org.eclipse.jem.internal.proxy.ide.IIDEBeanProxy;

public class IDEDimensionBeanTypeProxy
  extends IDEBeanTypeProxy
{
  IDEDimensionBeanTypeProxy(IDEProxyFactoryRegistry aRegistry)
  {
    this(aRegistry, Dimension.class);
  }
  
  private IDEDimensionBeanTypeProxy(IDEProxyFactoryRegistry aRegistry, Class type)
  {
    super(aRegistry, type);
  }
  
  protected IIDEBeanProxy newBeanProxy(Object anObject)
  {
    return new IDEDimensionBeanProxy(fProxyFactoryRegistry, anObject, this);
  }
  
  IDEDimensionBeanProxy createDimensionBeanProxy(int width, int height)
  {
    return new IDEDimensionBeanProxy(fProxyFactoryRegistry, new Dimension(width, height), this);
  }
  
  public IDEBeanTypeProxy newBeanTypeForClass(Class type)
  {
    return new IDEDimensionBeanTypeProxy(fProxyFactoryRegistry, type);
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.awt.IDEDimensionBeanTypeProxy
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide.awt;

import java.awt.Point;
import org.eclipse.jem.internal.proxy.core.IBeanTypeProxy;
import org.eclipse.jem.internal.proxy.core.IPointBeanProxy;
import org.eclipse.jem.internal.proxy.ide.IDEObjectBeanProxy;
import org.eclipse.jem.internal.proxy.ide.IDEProxyFactoryRegistry;

public class IDEPointBeanProxy
  extends IDEObjectBeanProxy
  implements IPointBeanProxy
{
  protected Point fPoint;
  
  IDEPointBeanProxy(IDEProxyFactoryRegistry aRegistry, Object aPoint, IBeanTypeProxy aBeanTypeProxy)
  {
    super(aRegistry, aPoint, aBeanTypeProxy);
    fPoint = ((Point)aPoint);
  }
  
  public int getX()
  {
    return fPoint.x;
  }
  
  public void setX(int anX)
  {
    fPoint.x = anX;
  }
  
  public int getY()
  {
    return fPoint.y;
  }
  
  public void setY(int aY)
  {
    fPoint.y = aY;
  }
  
  public void setLocation(IPointBeanProxy aBeanProxy)
  {
    fPoint.setLocation(new Point(aBeanProxy.getX(), aBeanProxy.getY()));
  }
  
  public void setLocation(int anX, int aY)
  {
    fPoint.x = anX;
    fPoint.y = aY;
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.awt.IDEPointBeanProxy
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide.awt;

import java.awt.Point;
import org.eclipse.jem.internal.proxy.ide.IDEBeanTypeProxy;
import org.eclipse.jem.internal.proxy.ide.IDEProxyFactoryRegistry;
import org.eclipse.jem.internal.proxy.ide.IIDEBeanProxy;

public class IDEPointBeanTypeProxy
  extends IDEBeanTypeProxy
{
  IDEPointBeanTypeProxy(IDEProxyFactoryRegistry aRegistry)
  {
    this(aRegistry, Point.class);
  }
  
  private IDEPointBeanTypeProxy(IDEProxyFactoryRegistry aRegistry, Class type)
  {
    super(aRegistry, type);
  }
  
  protected IIDEBeanProxy newBeanProxy(Object anObject)
  {
    return new IDEPointBeanProxy(fProxyFactoryRegistry, anObject, this);
  }
  
  IDEPointBeanProxy createPointBeanProxy(int x, int y)
  {
    return new IDEPointBeanProxy(fProxyFactoryRegistry, new Point(x, y), this);
  }
  
  public IDEBeanTypeProxy newBeanTypeForClass(Class type)
  {
    return new IDEPointBeanTypeProxy(fProxyFactoryRegistry, type);
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.awt.IDEPointBeanTypeProxy
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide.awt;

import java.awt.Rectangle;
import org.eclipse.jem.internal.proxy.core.IBeanTypeProxy;
import org.eclipse.jem.internal.proxy.core.IDimensionBeanProxy;
import org.eclipse.jem.internal.proxy.core.IPointBeanProxy;
import org.eclipse.jem.internal.proxy.core.IRectangleBeanProxy;
import org.eclipse.jem.internal.proxy.ide.IDEObjectBeanProxy;
import org.eclipse.jem.internal.proxy.ide.IDEProxyFactoryRegistry;

public class IDERectangleBeanProxy
  extends IDEObjectBeanProxy
  implements IRectangleBeanProxy
{
  protected Rectangle fRectangle;
  
  IDERectangleBeanProxy(IDEProxyFactoryRegistry aRegistry, Object aRectangle, IBeanTypeProxy aBeanTypeProxy)
  {
    super(aRegistry, aRectangle, aBeanTypeProxy);
    fRectangle = ((Rectangle)aRectangle);
  }
  
  public int getX()
  {
    return fRectangle.x;
  }
  
  public void setX(int anX)
  {
    fRectangle.x = anX;
  }
  
  public int getY()
  {
    return fRectangle.y;
  }
  
  public void setY(int aY)
  {
    fRectangle.y = aY;
  }
  
  public int getHeight()
  {
    return fRectangle.height;
  }
  
  public void setHeight(int aHeight)
  {
    fRectangle.height = aHeight;
  }
  
  public void setWidth(int aWidth)
  {
    fRectangle.width = aWidth;
  }
  
  public int getWidth()
  {
    return fRectangle.width;
  }
  
  public void setBounds(IRectangleBeanProxy aBeanProxy)
  {
    fRectangle.setBounds(aBeanProxy.getX(), aBeanProxy.getY(), aBeanProxy.getWidth(), aBeanProxy.getHeight());
  }
  
  public void setBounds(int x, int y, int width, int height)
  {
    fRectangle.setBounds(x, y, width, height);
  }
  
  public void setSize(IDimensionBeanProxy aBeanProxy)
  {
    fRectangle.setSize(aBeanProxy.getWidth(), aBeanProxy.getWidth());
  }
  
  public void setLocation(IPointBeanProxy aBeanProxy)
  {
    fRectangle.setLocation(aBeanProxy.getX(), aBeanProxy.getY());
  }
  
  public void setLocation(int x, int y)
  {
    fRectangle.setLocation(x, y);
  }
  
  public void setSize(int width, int height)
  {
    fRectangle.setSize(width, height);
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.awt.IDERectangleBeanProxy
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide.awt;

import java.awt.Rectangle;
import org.eclipse.jem.internal.proxy.ide.IDEBeanTypeProxy;
import org.eclipse.jem.internal.proxy.ide.IDEProxyFactoryRegistry;
import org.eclipse.jem.internal.proxy.ide.IIDEBeanProxy;

public class IDERectangleBeanTypeProxy
  extends IDEBeanTypeProxy
{
  IDERectangleBeanTypeProxy(IDEProxyFactoryRegistry aRegistry)
  {
    this(aRegistry, Rectangle.class);
  }
  
  private IDERectangleBeanTypeProxy(IDEProxyFactoryRegistry aRegistry, Class type)
  {
    super(aRegistry, type);
  }
  
  protected IIDEBeanProxy newBeanProxy(Object anObject)
  {
    return new IDERectangleBeanProxy(fProxyFactoryRegistry, anObject, this);
  }
  
  IDERectangleBeanProxy createRectangleBeanProxy(int x, int y, int width, int height)
  {
    return new IDERectangleBeanProxy(fProxyFactoryRegistry, new Rectangle(x, y, width, height), this);
  }
  
  public IDEBeanTypeProxy newBeanTypeForClass(Class type)
  {
    return new IDERectangleBeanTypeProxy(fProxyFactoryRegistry, type);
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.awt.IDERectangleBeanTypeProxy
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide.awt;

import org.eclipse.jem.internal.proxy.ide.IDEProxyFactoryRegistry;

public final class IDERegisterAWT
{
  public static void registerAWT(IDEProxyFactoryRegistry registry)
  {
    new IDEStandardAWTBeanTypeProxyFactory(registry);
    new IDEStandardAWTBeanProxyFactory(registry);
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.awt.IDERegisterAWT
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide.awt;

import org.eclipse.jem.internal.proxy.awt.IStandardAwtBeanProxyFactory;
import org.eclipse.jem.internal.proxy.core.IDimensionBeanProxy;
import org.eclipse.jem.internal.proxy.core.IPointBeanProxy;
import org.eclipse.jem.internal.proxy.core.IRectangleBeanProxy;
import org.eclipse.jem.internal.proxy.ide.IDEProxyFactoryRegistry;

class IDEStandardAWTBeanProxyFactory
  implements IStandardAwtBeanProxyFactory
{
  final IDEStandardAWTBeanTypeProxyFactory fAWTBeanTypeFactory;
  
  public IDEStandardAWTBeanProxyFactory(IDEProxyFactoryRegistry factory)
  {
    factory.registerBeanProxyFactory("standard-java.awt", this);
    fAWTBeanTypeFactory = ((IDEStandardAWTBeanTypeProxyFactory)factory.getBeanTypeProxyFactoryExtension("java.awt"));
  }
  
  public IDimensionBeanProxy createDimensionBeanProxyWith(int width, int height)
  {
    return fAWTBeanTypeFactory.dimensionType.createDimensionBeanProxy(width, height);
  }
  
  public IPointBeanProxy createPointBeanProxyWith(int x, int y)
  {
    return fAWTBeanTypeFactory.pointType.createPointBeanProxy(x, y);
  }
  
  public IRectangleBeanProxy createBeanProxyWith(int x, int y, int width, int height)
  {
    return fAWTBeanTypeFactory.rectangleType.createRectangleBeanProxy(x, y, width, height);
  }
  
  public void terminateFactory(boolean wait) {}
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.awt.IDEStandardAWTBeanProxyFactory
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.ide.awt;

import org.eclipse.jem.internal.proxy.core.IBeanTypeProxy;
import org.eclipse.jem.internal.proxy.core.IExpression;
import org.eclipse.jem.internal.proxy.core.IProxyBeanType;
import org.eclipse.jem.internal.proxy.ide.IDEBeanTypeProxy;
import org.eclipse.jem.internal.proxy.ide.IDEExtensionBeanTypeProxyFactory;
import org.eclipse.jem.internal.proxy.ide.IDEProxyFactoryRegistry;

class IDEStandardAWTBeanTypeProxyFactory
  implements IDEExtensionBeanTypeProxyFactory
{
  static final String BEAN_TYPE_FACTORY_KEY = "java.awt";
  protected final IDEProxyFactoryRegistry fFactoryRegistry;
  protected final IDEDimensionBeanTypeProxy dimensionType;
  protected final IDEPointBeanTypeProxy pointType;
  protected final IDERectangleBeanTypeProxy rectangleType;
  
  IDEStandardAWTBeanTypeProxyFactory(IDEProxyFactoryRegistry aRegistry)
  {
    fFactoryRegistry = aRegistry;
    fFactoryRegistry.registerBeanTypeProxyFactory("java.awt", this);
    dimensionType = new IDEDimensionBeanTypeProxy(fFactoryRegistry);
    pointType = new IDEPointBeanTypeProxy(fFactoryRegistry);
    rectangleType = new IDERectangleBeanTypeProxy(fFactoryRegistry);
  }
  
  public IDEBeanTypeProxy getExtensionBeanTypeProxy(String className)
  {
    if ("java.awt.Dimension".equals(className)) {
      return dimensionType;
    }
    if ("java.awt.Point".equals(className)) {
      return pointType;
    }
    if ("java.awt.Rectangle".equals(className)) {
      return rectangleType;
    }
    return null;
  }
  
  public IDEBeanTypeProxy getExtensionBeanTypeProxy(String className, IBeanTypeProxy beanTypeProxy)
  {
    return getExtensionBeanTypeProxy(className);
  }
  
  public IProxyBeanType getExtensionBeanTypeProxy(String typeName, IExpression expression)
  {
    return getExtensionBeanTypeProxy(typeName);
  }
  
  public void terminateFactory(boolean wait) {}
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.ide.awt.IDEStandardAWTBeanTypeProxyFactory
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.initParser;

import java.io.StringWriter;
import java.lang.reflect.Array;
import java.util.ArrayList;
import java.util.List;

public class ArrayArguments
  extends Expression
{
  Static fType;
  List arguments = new ArrayList(2);
  boolean argsClosed;
  boolean insideArgsOpenedParen;
  boolean insideArgsClosedParen;
  
  public Expression push(char[] token, char tokenDelimiter)
  {
    if (!argsClosed)
    {
      if (arguments.size() > 0)
      {
        Expression openArgument = (Expression)arguments.get(arguments.size() - 1);
        if (!openArgument.isComplete())
        {
          openArgument.push(token, tokenDelimiter);
          if ((openArgument.isComplete()) && (tokenDelimiter == '}')) {
            argsClosed = true;
          }
          return this;
        }
      }
      Expression newArgument = null;
      if ((!insideArgsOpenedParen) && (tokenDelimiter == '('))
      {
        insideArgsOpenedParen = true;
        newArgument = new Statement(fClassLoader).push(token, tokenDelimiter);
        newArgument = new MessageArgument(newArgument);
        arguments.add(newArgument);
      }
      if ((token.length > 0) || (tokenDelimiter == '"') || (tokenDelimiter == '\'') || (tokenDelimiter == '-'))
      {
        newArgument = new Statement(fClassLoader).push(token, tokenDelimiter);
        newArgument = new MessageArgument(newArgument);
        arguments.add(newArgument);
      }
      if ((!insideArgsOpenedParen) && (tokenDelimiter == '}'))
      {
        argsClosed = true;
        return this;
      }
      if ((insideArgsOpenedParen) && (tokenDelimiter == '}'))
      {
        insideArgsClosedParen = true;
        argsClosed = true;
        return this;
      }
    }
    return this;
  }
  
  public Object evaluate()
    throws Exception
  {
    Object result = Array.newInstance(fType.getPrimitiveTypeClass(), arguments.size());
    for (int i = 0; i < arguments.size(); i++)
    {
      Object argumentValue = ((Expression)arguments.get(i)).evaluate();
      Array.set(result, i, argumentValue);
    }
    return result;
  }
  
  public Class getTypeClass()
    throws Exception
  {
    return null;
  }
  
  public boolean isComplete()
  {
    return argsClosed;
  }
  
  public boolean isPrimitive()
    throws Exception
  {
    return false;
  }
  
  public void setType(Static type)
  {
    fType = type;
  }
  
  public void contributeArgumentNumber(List argumentNumberList)
  {
    argumentNumberList.add(new Integer(arguments.size()));
    if (arguments.size() > 0)
    {
      Object firstArgument = arguments.get(0);
      (firstArgument instanceof ArrayArguments);
    }
  }
  
  public String toString()
  {
    StringWriter writer = new StringWriter();
    writer.write("Args(");
    writer.write(new Integer(arguments.size()).toString());
    writer.write(")-");
    writer.write(arguments.toString());
    return writer.toString();
  }
  
  protected String getTypeClassName()
  {
    return "";
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.initParser.ArrayArguments
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.initParser;

public class Block
  extends Expression
{
  protected boolean fIsClosed = false;
  protected boolean fIsComplete = false;
  protected boolean fMessageOrField = false;
  
  public Block(Expression anExpression)
  {
    currentExpression = anExpression;
  }
  
  public Block(ClassLoader fClassLoader)
  {
    currentExpression = new Statement(fClassLoader);
  }
  
  public Object evaluate()
    throws Exception
  {
    return currentExpression.evaluate();
  }
  
  public boolean isComplete()
  {
    return fIsComplete;
  }
  
  public Class getTypeClass()
    throws Exception
  {
    return currentExpression.getTypeClass();
  }
  
  public Expression push(char[] token, char tokenDelimiter)
  {
    if (((fIsClosed) || (currentExpression.isComplete())) && ((tokenDelimiter == ')') || (tokenDelimiter == ',')))
    {
      fIsComplete = true;
      return this;
    }
    if (fMessageOrField)
    {
      fMessageOrField = false;
      if (tokenDelimiter == '(')
      {
        Message message = new Message(currentExpression, token, fClassLoader);
        currentExpression = message;
        return message;
      }
      Field field = new Field(currentExpression, token, fClassLoader);
      currentExpression = field;
      return field;
    }
    if ((currentExpression.isComplete()) && (tokenDelimiter == '.'))
    {
      fMessageOrField = true;
      return this;
    }
    Expression result = currentExpression.push(token, tokenDelimiter);
    if (result != currentExpression) {
      pushExpressionStack(result);
    }
    if ((currentExpression.isComplete()) && (tokenDelimiter == ')')) {
      fIsClosed = true;
    }
    return currentExpression;
  }
  
  public boolean isPrimitive()
    throws Exception
  {
    return false;
  }
  
  public String toString()
  {
    StringBuffer buffer = new StringBuffer();
    buffer.append("Block(");
    if (currentExpression != null) {
      buffer.append(currentExpression.toString());
    }
    buffer.append(')');
    return buffer.toString();
  }
  
  protected String getTypeClassName()
  {
    return currentExpression.getTypeClassName();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.initParser.Block
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.initParser;

public class BooleanLiteral
  extends Expression
{
  public boolean value;
  
  public BooleanLiteral(boolean aValue)
  {
    value = aValue;
  }
  
  public boolean isComplete()
  {
    return true;
  }
  
  public Object evaluate()
  {
    return new Boolean(value);
  }
  
  public Class getTypeClass()
  {
    return Boolean.TYPE;
  }
  
  public Expression push(char[] token, char delimiter)
  {
    return null;
  }
  
  public boolean isPrimitive()
  {
    return true;
  }
  
  protected String getTypeClassName()
  {
    return Boolean.TYPE.getName();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.initParser.BooleanLiteral
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.initParser;

public class CannotProcessArrayTypesException
  extends RuntimeException
{
  private static final long serialVersionUID = -4245984020065761634L;
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.initParser.CannotProcessArrayTypesException
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.initParser;

public class CannotProcessInnerClassesException
  extends RuntimeException
{
  private static final long serialVersionUID = 8290504580738499445L;
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.initParser.CannotProcessInnerClassesException
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.initParser;

import java.util.HashMap;

public class Cast
  extends Expression
{
  protected static final int BYTE_TYPE = 0;
  protected static final int SHORT_TYPE = 1;
  protected static final int INT_TYPE = 2;
  protected static final int LONG_TYPE = 3;
  protected static final int FLOAT_TYPE = 4;
  protected static final int DOUBLE_TYPE = 5;
  protected static final HashMap sTypeLookup = new HashMap(6);
  protected Static fCastType;
  
  static
  {
    sTypeLookup.put(Byte.TYPE, new Integer(0));
    sTypeLookup.put(Short.TYPE, new Integer(1));
    sTypeLookup.put(Integer.TYPE, new Integer(2));
    sTypeLookup.put(Long.TYPE, new Integer(3));
    sTypeLookup.put(Float.TYPE, new Integer(4));
    sTypeLookup.put(Double.TYPE, new Integer(5));
  }
  
  protected boolean fIsClosed = false;
  
  public Cast(Static castType, ClassLoader aClassLoader)
  {
    fCastType = castType;
    fClassLoader = aClassLoader;
  }
  
  public boolean isPrimitive()
    throws Exception
  {
    return getTypeClass().isPrimitive();
  }
  
  public Class getTypeClass()
    throws Exception
  {
    return fCastType.getTypeClass();
  }
  
  public boolean isComplete()
  {
    return (currentExpression != null) && (currentExpression.isComplete());
  }
  
  public Object evaluate()
    throws Exception
  {
    if (getTypeClass() == currentExpression.getTypeClass()) {
      return currentExpression.evaluate();
    }
    if (getTypeClass().isPrimitive())
    {
      if ((!currentExpression.getTypeClass().isPrimitive()) || (currentExpression.getTypeClass() == Void.TYPE)) {
        throw new EvaluationException(new ClassCastException(currentExpression.getTypeClass().getName()));
      }
      if ((fCastType.getTypeClass() == Boolean.TYPE) || (currentExpression.getTypeClass() == Boolean.TYPE)) {
        throw new EvaluationException(new ClassCastException(currentExpression.getTypeClass().getName()));
      }
      if (fCastType.getTypeClass() == Character.TYPE) {
        return new Character((char)((Number)currentExpression.evaluate()).intValue());
      }
      Number value = null;
      if (currentExpression.getTypeClass() == Character.TYPE) {
        value = new Integer(((Character)currentExpression.evaluate()).charValue());
      } else {
        value = (Number)currentExpression.evaluate();
      }
      switch (((Integer)sTypeLookup.get(fCastType.getTypeClass())).intValue())
      {
      case 0: 
        return new Byte(value.byteValue());
      case 1: 
        return new Short(value.shortValue());
      case 2: 
        return new Integer(value.intValue());
      case 3: 
        return new Long(value.longValue());
      case 4: 
        return new Float(value.floatValue());
      case 5: 
        return new Double(value.doubleValue());
      }
      return null;
    }
    return currentExpression.evaluate();
  }
  
  public Expression push(char[] token, char tokenDelimiter)
  {
    if ((fCastType.getPrimitiveTypeClass() == null) && (!fIsClosed))
    {
      fCastType.push(token, tokenDelimiter);
      if ((fCastType.getPrimitiveTypeClass() != null) && (tokenDelimiter == ')')) {
        fIsClosed = true;
      }
      return this;
    }
    if (!fIsClosed)
    {
      Expression result = fCastType.push(token, tokenDelimiter);
      parenthesisLevel += 1;
      return result;
    }
    if (currentExpression == null)
    {
      currentExpression = new Statement(fClassLoader);
      currentExpression = currentExpression.push(token, tokenDelimiter);
      return this;
    }
    Expression result = currentExpression.push(token, tokenDelimiter);
    if (result.isComplete()) {
      popExpressionStack();
    } else if (result != currentExpression) {
      pushExpressionStack(result);
    }
    return this;
  }
  
  public String toString()
  {
    StringBuffer buffer = new StringBuffer();
    buffer.append("Cast(");
    if (fCastType != null) {
      buffer.append(fCastType.toString());
    } else {
      buffer.append("???");
    }
    buffer.append(") ");
    if (currentExpression != null) {
      buffer.append(currentExpression.toString());
    } else {
      buffer.append("???");
    }
    return buffer.toString();
  }
  
  protected String getTypeClassName()
  {
    return fCastType.getTypeClassName();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.initParser.Cast
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.initParser;

import java.text.MessageFormat;

public class CharLiteral
  extends Expression
{
  protected boolean isComplete;
  public char value;
  public StringBuffer valueBuffer = new StringBuffer();
  protected boolean isEscaped = false;
  
  public Object evaluate()
    throws Exception
  {
    if (valueBuffer.length() == 1) {
      return new Character(valueBuffer.charAt(0));
    }
    throw new EvaluationException(
      new IllegalArgumentException(MessageFormat.format(ProxyInitParserMessages.getString("CharTooComplicated_EXC_"), 
      new Object[] { valueBuffer.toString() })));
  }
  
  public boolean isComplete()
  {
    return isComplete;
  }
  
  public Class getTypeClass()
  {
    return Character.TYPE;
  }
  
  protected String getTypeClassName()
  {
    return Character.TYPE.getName();
  }
  
  public Expression push(char[] token, char delimiter)
  {
    if (isEscaped)
    {
      isEscaped = false;
      if (token.length != 0)
      {
        valueBuffer.append('\\');
      }
      else
      {
        if ((delimiter == '\'') || (delimiter == '\\'))
        {
          valueBuffer.append(delimiter);
        }
        else
        {
          valueBuffer.append('\\');
          valueBuffer.append(delimiter);
        }
        return this;
      }
    }
    valueBuffer.append(token);
    if (delimiter == '\'')
    {
      isComplete = true;
      return this;
    }
    if (delimiter == '\\') {
      isEscaped = true;
    } else {
      valueBuffer.append(delimiter);
    }
    return this;
  }
  
  public boolean isPrimitive()
  {
    return true;
  }
  
  public String toString()
  {
    StringBuffer buffer = new StringBuffer();
    buffer.append("Char('");
    if (valueBuffer != null) {
      buffer.append(valueBuffer.toString());
    }
    buffer.append(')');
    return buffer.toString();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.jem.internal.proxy.initParser.CharLiteral
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.jem.internal.proxy.initParser;

import java.io.StringWriter;
import java.util.ArrayList;
import java.util.Iterator;
import org.eclipse.jem.internal.proxy.common.AmbiguousMethodException;
import org.eclipse.jem.internal.proxy.common.MethodHelper;

public class Constructor
  extends Expression
{
  public boolean argsOpened = false;
  public boolean argsClosed = false;
  public boolean trailingPeriod = false;
  public ArrayList arguments = new ArrayList(2);
  public Static type;
  protected boolean fIsComplete;
  public boolean insideArgsOpenedParen = false;
  public boolean insideArgsClosedParen = false;
  public boolean isString = false;
  public java.lang.reflect.Constructor ctor;
  
  public Constructor(ClassLoader aClassLoader)
  {
    fClassLoader = aClassLoader;
  }
  
  public boolean isComplete()
  {
    return fIsComplete;
  }
  
  public Object evaluate()
    throws Exception
  {
    if (type.isArray())
    {
      if (arguments.size() > 0) {
        type.setArrayArguments(arguments);
      }
      Object result = type.evaluate();
      
      return result;
    }
    cacheCtor();
    
    Object[] args = new Object[arguments.size()];
    Iterator itr = arguments.iterator();
    for (int i = 0; i < arguments.size(); i++)
    {
      Expression anExpression = (Expression)itr.next();
      args[i] = anExpression.evaluate();
    }
    try
    {
      return ctor.newInstance(args);
    }
    catch (Exception e)
    {
      throw new EvaluationException(e);
    }
  }
  
  public Class getTypeClass()
    throws Exception
  {
    if (type.isArray()) {
      if (arguments.size() > 0) {
        type.setArrayArguments(arguments);
      }
    }
    return type.getTypeClass();
  }
  
  protected String getTypeClassName()
  {
    return type.getTypeClassName();
  }
  
  private void cacheCtor()
    throws Exception
  {
    if (ctor == null)
    {
      Class[] argTypes = new Class[arguments.size()];
      Iterator itr = arguments.iterator();
      for (int i = 0; i < argTypes.length; i++) {
        argTypes[i] = getEvaluationTypeClass((Expression)itr.next());
      }
      try
      {
        ctor = MethodHelper.findCompatibleConstructor(getEvaluationTypeClass(this), argTypes);
      }
      catch (NoSuchMethodException e)
      {
        throw new EvaluationException(e);
      }
      catch (AmbiguousMethodException e)
      {
        throw new EvaluationException(e);
      }
      catch (IllegalAccessException e)
      {
        throw new EvaluationException(e);
      }
    }
  }
  
  protected boolean isDelimiterOpened(char token)
  {
    return token == '{';
  }
  
  protected boolean isDelimiterClosed(char token)
  {
    return token == '}';
  }
  
  public Expression push(char[] token, char tokenDelimiter)
  {
    if ((argsClosed) && (!trailingPeriod) && (tokenDelimiter == '.') && (token.length == 0))
    {
      trailingPeriod = true;
      return this;
    }
    if ((trailingPeriod) && (tokenDelimiter == '.')) {
      return new Field(this, token, fClassLoader);
    }
    if ((trailingPeriod) && (tokenDelimiter == '(')) {
      return new Message(this, token, fClassLoader);
    }
    if (type == null)
    {
      switch (tokenDelimiter)
      {
      case '.': 
        type = new Static(token, tokenDelimiter, fClassLoader);
        type.setClassLoader(fClassLoader);
        return this;
      case '(': 
        type = new Static(token, tokenDelimiter, fClassLoader);
        type.setClassLoader(fClassLoader);
        argsOpened = true;
        return this;
      case '[': 
        type = new Static(token, tokenDelimiter, fClassLoader, true);
        return this;
      case '{': 
        if ((type != null) && (type.isArray())) {
          argsOpened = true;
        }
        break;
      }
      return null;
    }
    if ((type != null) && (type.isArray())) {
      if ((type.isProcessingArrayDimension) || (tokenDelimiter == '['))
      {
        type.push(token, tokenDelimiter);
        return this;
      }
    }
    if ((!type.isArray()) && (type.getTypeClass() == null) && ((tokenDelimiter == '.') || (tokenDelimiter == '[')))
    {
      type.push(token, tokenDelimiter);
      return this;
    }
    if (!type.isArray())
    {
      if ((type.getTypeClass() == null) && (!argsOpened) && (isDelimiterOpened(tokenDelimiter)))
      {
        argsOpened = true;
        insideArgsOpenedParen = true;
       
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30

Further reading...

For more information on Java 1.5 Tiger, you may find Java 1.5 Tiger, A developer's Notebook by D. Flanagan and B. McLaughlin from O'Reilly of interest.

New!JAR listings


Copyright 2006-2017. Infinite Loop Ltd