home *** CD-ROM | disk | FTP | other *** search
/ PC Online 1997 August / PCO0897.ISO / filesbbs / os2 / fp1os2.arj / OS2 / DATA / 49 / C / 0 / F_26836 / JScriptPluginsMemberObject.class (.txt) < prev    next >
Encoding:
Java Class File  |  1997-05-15  |  2.8 KB  |  108 lines

  1. public class JScriptPluginsMemberObject extends JSbxArrayObject {
  2.    private static final int PLUGINS_ID_NAME = 257;
  3.    private static final int PLUGINS_ID_FILENAME = 258;
  4.    private static final int PLUGINS_ID_DESCRIPTION = 259;
  5.  
  6.    public JScriptPluginsMemberObject(long var1) {
  7.       super(var1);
  8.  
  9.       try {
  10.          ((JSbxObject)this).Put(new JSbxObjectProperty("name", this, this, 257, true));
  11.          ((JSbxObject)this).Put(new JSbxObjectProperty("filename", this, this, 258, true));
  12.          ((JSbxObject)this).Put(new JSbxObjectProperty("description", this, this, 259, true));
  13.       } catch (JSbxException var3) {
  14.          System.out.println("Unerwartete Exception im JScriptPluginsObject()-Ctor");
  15.       }
  16.    }
  17.  
  18.    public JSbxValue PropertyCallFunction(JSbxObjectProperty var1, JScriptCallParam var2) throws JSbxExceptionBase {
  19.       var2.GetParamVector();
  20.       int var3 = var1.GetID();
  21.       String var4 = "";
  22.       double var5 = (double)0.0F;
  23.       boolean var7 = false;
  24.       boolean var8 = true;
  25.  
  26.       try {
  27.          switch (var3) {
  28.             case 0:
  29.             default:
  30.                return super.PropertyCallFunction(var1, var2);
  31.          }
  32.       } catch (UnsatisfiedLinkError var10) {
  33.          JScriptManager.GetMyJScriptManager();
  34.          JScriptManager.ShowWarning("Exception: " + var10);
  35.          Object var9 = null;
  36.          JSbxValue var11;
  37.          if (var8) {
  38.             var11 = new JSbxValue();
  39.          } else if (var7) {
  40.             var11 = new JSbxValue(var5);
  41.          } else {
  42.             var11 = new JSbxValue(var4);
  43.          }
  44.  
  45.          var2.GetRuntimeParam().SetReturnValue(var11);
  46.          return var11;
  47.       }
  48.    }
  49.  
  50.    public void PropertyGet(JSbxObjectProperty var1, JSbxValue var2) throws JSbxException {
  51.       int var3 = var1.GetID();
  52.  
  53.       try {
  54.          switch (var3) {
  55.             case 257:
  56.                var2.Put(new JSbxValue(this.getName()));
  57.                return;
  58.             case 258:
  59.                var2.Put(new JSbxValue(this.getFilename()));
  60.                return;
  61.             case 259:
  62.                var2.Put(new JSbxValue(this.getDescription()));
  63.                return;
  64.             default:
  65.                super.PropertyGet(var1, var2);
  66.          }
  67.       } catch (UnsatisfiedLinkError var5) {
  68.          JScriptManager.GetMyJScriptManager();
  69.          JScriptManager.ShowWarning("Exception: " + var5);
  70.       }
  71.    }
  72.  
  73.    public void PropertyPut(JSbxObjectProperty var1, JSbxValue var2) throws JSbxException {
  74.       int var3 = var1.GetID();
  75.  
  76.       try {
  77.          switch (var3) {
  78.             case 0:
  79.             default:
  80.                super.PropertyPut(var1, var2);
  81.          }
  82.       } catch (UnsatisfiedLinkError var5) {
  83.          JScriptManager.GetMyJScriptManager();
  84.          JScriptManager.ShowWarning("Exception: " + var5);
  85.       }
  86.    }
  87.  
  88.    public String Property_GetJScript_typeofString(JSbxObjectProperty var1) {
  89.       return "plugins";
  90.    }
  91.  
  92.    public String GetJScriptString(boolean var1) {
  93.       return "plugins";
  94.    }
  95.  
  96.    private native String getName();
  97.  
  98.    private native String getFilename();
  99.  
  100.    private native String getDescription();
  101.  
  102.    protected native int getLength();
  103.  
  104.    protected native JSbxObject getElement(int var1);
  105.  
  106.    protected native JSbxObject getElement_String(String var1);
  107. }
  108.