Esempio n. 1
0
 /// <summary>Returns an instance of type InitialContext if the given proxy instance
 /// represents a Java object that is type-compatible with javax.naming.InitialContext</summary>
 /// This function returns <c>null</c> if the passed object is not a type-compatible
 /// proxy object.
 /// <param name="proxy">A proxy object of any type.</param>
 public static new global::Javax.Naming.InitialContext From( object proxy )
 {
     global::Codemesh.JuggerNET.JavaProxy   jp = proxy as global::Codemesh.JuggerNET.JavaProxy;
     if (jp != null && _cmj_theClass.IsTypeOf(jp))
         return new global::Javax.Naming.InitialContext(new global::Codemesh.JuggerNET.JNIHandle(jp.JObjectDuplicate));
     else
         return null;
 }
Esempio n. 2
0
 /// <summary>Casts another proxy object to this type if possible.
 /// <para>You rarely need this method. It is only required when you have for example
 /// an array proxy type that is type compatible on the Java side but not on the .NET side.</para>
 /// <para>A good example would be the <c>String[][]</c> and <c>Object[]</c> types in Java.
 /// The two-dimensional String array IS also a one-dimensional Object array in Java, but we cannot
 /// duplicate this behavior through inheritance in .NET.  For that reason, we provide you with this
 /// method, allowing you to take for exmaple a <c>StringArrayArray</c> object and use it to create
 /// an <c>ObjectArray</c> instance when you need to.</para></summary>
 public static JDBCTypeArray From(global::Codemesh.JuggerNET.JavaProxy proxy)
 {
     if (_cmj_theClass.IsTypeOf(proxy))
     {
         return(new JDBCTypeArray(new global::Codemesh.JuggerNET.JNIHandle(proxy.JObjectDuplicate)));
     }
     else
     {
         return(null);
     }
 }
Esempio n. 3
0
 /// <summary>Returns an instance of type Date if the given proxy instance
 /// represents a Java object that is type-compatible with java.sql.Date</summary>
 /// This function returns <c>null</c> if the passed object is not a type-compatible
 /// proxy object.
 /// <param name="proxy">A proxy object of any type.</param>
 public static new global::Java.Sql.Date From(object proxy)
 {
     global::Codemesh.JuggerNET.JavaProxy jp = proxy as global::Codemesh.JuggerNET.JavaProxy;
     if (jp != null && _cmj_theClass.IsTypeOf(jp))
     {
         return(new global::Java.Sql.Date(new global::Codemesh.JuggerNET.JNIHandle(jp.JObjectDuplicate)));
     }
     else
     {
         return(null);
     }
 }
Esempio n. 4
0
 /// <summary>Returns an instance of type InputStreamImpl if the given proxy instance
 /// represents a Java object that is type-compatible with java.io.InputStream</summary>
 /// <param name="proxy">A proxy object of any type.</param>
 public static new global::Java.Io.InputStream.InputStreamImpl From(object proxy)
 {
     global::Codemesh.JuggerNET.JavaProxy jp = proxy as global::Codemesh.JuggerNET.JavaProxy;
     if (_cmj_theClass.IsTypeOf(jp))
     {
         return(new global::Java.Io.InputStream.InputStreamImpl(new global::Codemesh.JuggerNET.JNIHandle(jp.JObjectDuplicate)));
     }
     else
     {
         return(null);
     }
 }
Esempio n. 5
0
 /// <summary>Returns an instance of type UnaryOperatorImpl if the given proxy instance
 /// represents a Java object that is type-compatible with java.util.function.UnaryOperator</summary>
 /// <param name="proxy">A proxy object of any type.</param>
 public static new global::Java.Util.Function.UnaryOperatorImpl From(object proxy)
 {
     global::Codemesh.JuggerNET.JavaProxy jp = proxy as global::Codemesh.JuggerNET.JavaProxy;
     if (_cmj_theClass.IsTypeOf(jp))
     {
         return(new global::Java.Util.Function.UnaryOperatorImpl(new global::Codemesh.JuggerNET.JNIHandle(jp.JObjectDuplicate)));
     }
     else
     {
         return(null);
     }
 }
Esempio n. 6
0
 /// <summary>Returns an instance of type RowSetMetaDataImpl if the given proxy instance
 /// represents a Java object that is type-compatible with javax.sql.RowSetMetaData</summary>
 /// <param name="proxy">A proxy object of any type.</param>
 public static new global::Javax.Sql.RowSetMetaDataImpl From(object proxy)
 {
     global::Codemesh.JuggerNET.JavaProxy jp = proxy as global::Codemesh.JuggerNET.JavaProxy;
     if (_cmj_theClass.IsTypeOf(jp))
     {
         return(new global::Javax.Sql.RowSetMetaDataImpl(new global::Codemesh.JuggerNET.JNIHandle(jp.JObjectDuplicate)));
     }
     else
     {
         return(null);
     }
 }
Esempio n. 7
0
 /// <summary>Returns an instance of type GenericDeclarationImpl if the given proxy instance
 /// represents a Java object that is type-compatible with java.lang.reflect.GenericDeclaration</summary>
 /// <param name="proxy">A proxy object of any type.</param>
 public static new global::Java.Lang.Reflect.GenericDeclarationImpl From(object proxy)
 {
     global::Codemesh.JuggerNET.JavaProxy jp = proxy as global::Codemesh.JuggerNET.JavaProxy;
     if (_cmj_theClass.IsTypeOf(jp))
     {
         return(new global::Java.Lang.Reflect.GenericDeclarationImpl(new global::Codemesh.JuggerNET.JNIHandle(jp.JObjectDuplicate)));
     }
     else
     {
         return(null);
     }
 }
Esempio n. 8
0
 /// <summary>Returns an instance of type ResultImpl if the given proxy instance
 /// represents a Java object that is type-compatible with javax.xml.transform.Result</summary>
 /// <param name="proxy">A proxy object of any type.</param>
 public static new global::Javax.Xml.Transform.ResultImpl From(object proxy)
 {
     global::Codemesh.JuggerNET.JavaProxy jp = proxy as global::Codemesh.JuggerNET.JavaProxy;
     if (_cmj_theClass.IsTypeOf(jp))
     {
         return(new global::Javax.Xml.Transform.ResultImpl(new global::Codemesh.JuggerNET.JNIHandle(jp.JObjectDuplicate)));
     }
     else
     {
         return(null);
     }
 }
Esempio n. 9
0
 /// <summary>Returns an instance of type AbstractCollection if the given proxy instance
 /// represents a Java object that is type-compatible with java.util.AbstractCollection</summary>
 /// This function returns <c>null</c> if the passed object is not a type-compatible
 /// proxy object.
 /// <param name="proxy">A proxy object of any type.</param>
 public static new global::Java.Util.AbstractCollection From(object proxy)
 {
     global::Codemesh.JuggerNET.JavaProxy jp = proxy as global::Codemesh.JuggerNET.JavaProxy;
     if (jp != null && _cmj_theClass.IsTypeOf(jp))
     {
         return(new global::Java.Util.AbstractCollection.AbstractCollectionImpl(new global::Codemesh.JuggerNET.JNIHandle(jp.JObjectDuplicate)));
     }
     else
     {
         return(null);
     }
 }
 /// <summary>Returns an instance of type SQLIntegrityConstraintViolationException if the given proxy instance
 /// represents a Java object that is type-compatible with java.sql.SQLIntegrityConstraintViolationException</summary>
 /// This function returns <c>null</c> if the passed object is not a type-compatible
 /// proxy object.
 /// <param name="proxy">A proxy object of any type.</param>
 public static new global::Java.Sql.SQLIntegrityConstraintViolationException From(object proxy)
 {
     global::Codemesh.JuggerNET.JavaProxy jp = proxy as global::Codemesh.JuggerNET.JavaProxy;
     if (jp != null && _cmj_theClass.IsTypeOf(jp))
     {
         return(new global::Java.Sql.SQLIntegrityConstraintViolationException(new global::Codemesh.JuggerNET.JNIHandle(jp.JObjectDuplicate)));
     }
     else
     {
         return(null);
     }
 }
Esempio n. 11
0
 /// <summary>Returns an instance of type BasicPermission if the given proxy instance
 /// represents a Java object that is type-compatible with java.security.BasicPermission</summary>
 /// This function returns <c>null</c> if the passed object is not a type-compatible
 /// proxy object.
 /// <param name="proxy">A proxy object of any type.</param>
 public static new global::Java.Security.BasicPermission From(object proxy)
 {
     global::Codemesh.JuggerNET.JavaProxy jp = proxy as global::Codemesh.JuggerNET.JavaProxy;
     if (jp != null && _cmj_theClass.IsTypeOf(jp))
     {
         return(new global::Java.Security.BasicPermission.BasicPermissionImpl(new global::Codemesh.JuggerNET.JNIHandle(jp.JObjectDuplicate)));
     }
     else
     {
         return(null);
     }
 }
Esempio n. 12
0
 /// <summary>Returns an instance of type SQLInvalidAuthorizationSpecException if the given proxy instance
 /// represents a Java object that is type-compatible with java.sql.SQLInvalidAuthorizationSpecException</summary>
 /// This function returns <c>null</c> if the passed object is not a type-compatible
 /// proxy object.
 /// <param name="proxy">A proxy object of any type.</param>
 public static new global::Java.Sql.SQLInvalidAuthorizationSpecException From(object proxy)
 {
     global::Codemesh.JuggerNET.JavaProxy jp = proxy as global::Codemesh.JuggerNET.JavaProxy;
     if (jp != null && _cmj_theClass.IsTypeOf(jp))
     {
         return(new global::Java.Sql.SQLInvalidAuthorizationSpecException(new global::Codemesh.JuggerNET.JNIHandle(jp.JObjectDuplicate)));
     }
     else
     {
         return(null);
     }
 }