private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__StatelessKnowledgeSessionResults);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getValue", "getValue0", "(Ljava/lang/String;)Ljava/lang/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getIdentifiers", "getIdentifiers1", "()Ljava/util/Collection;"));
     return methods;
 }
示例#2
1
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__ModuleN);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "InitN", "InitN0", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorModuleN0", "__ctorModuleN0", "(Lnet/sf/jni4net/inj/IClrProxy;)V"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__ProcessEvent);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getKnowledgeRuntime", "getKnowledgeRuntime0", "()Lorg/drools/runtime/KnowledgeRuntime;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getProcessInstance", "getProcessInstance1", "()Lorg/drools/runtime/process/ProcessInstance;"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__AfterRuleRemovedEvent);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getKnowledgeBase", "getKnowledgeBase0", "()Lorg/drools/KnowledgeBase;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getRule", "getRule1", "()Lorg/drools/definition/rule/Rule;"));
     return methods;
 }
示例#5
0
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__BridgeSetup);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getBindCLRTypes", "BindCLRTypes0", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setBindCLRTypes", "BindCLRTypes1", "(Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getVerbose", "Verbose2", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setVerbose", "Verbose3", "(Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getVeryVerbose", "VeryVerbose4", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setVeryVerbose", "VeryVerbose5", "(Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getDebug", "Debug6", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setDebug", "Debug7", "(Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getIgnoreJavaHome", "IgnoreJavaHome8", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setIgnoreJavaHome", "IgnoreJavaHome9", "(Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getBindNative", "BindNative10", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setBindNative", "BindNative11", "(Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getJavaHome", "JavaHome12", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setJavaHome", "JavaHome13", "(Ljava/lang/String;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getBindCoreOnly", "BindCoreOnly14", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setBindCoreOnly", "BindCoreOnly15", "(Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getBindStatic", "BindStatic16", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setBindStatic", "BindStatic17", "(Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getJVMOptions", "JVMOptions18", "()[Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getJVMCLassPath", "JVMCLassPath19", "()[Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "AddBridgeClassPath", "AddBridgeClassPath20", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "AddClassPath", "AddClassPath21", "(Ljava/lang/String;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "AddJVMOption", "AddJVMOption22", "(Ljava/lang/String;Ljava/lang/String;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "AddJVMOption", "AddJVMOption23", "(Ljava/lang/String;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "AddAllJarsClassPath", "AddAllJarsClassPath24", "(Ljava/lang/String;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorBridgeSetup0", "__ctorBridgeSetup0", "(Lnet/sf/jni4net/inj/IClrProxy;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorBridgeSetup1", "__ctorBridgeSetup1", "(Lnet/sf/jni4net/inj/IClrProxy;Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorBridgeSetup2", "__ctorBridgeSetup2", "(Lnet/sf/jni4net/inj/IClrProxy;[Ljava/lang/String;)V"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__Calendars);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "get", "get0", "(Ljava/lang/String;)Lorg/drools/time/Calendar;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "set", "set1", "(Ljava/lang/String;Lorg/drools/time/Calendar;)V"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__BeforeFunctionRemovedEvent);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getKnowledgeBase", "getKnowledgeBase0", "()Lorg/drools/KnowledgeBase;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getFunction", "getFunction1", "()Ljava/lang/String;"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__KnowledgeBuilderError);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getMessage", "getMessage0", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getErrorLines", "getErrorLines1", "()[I"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__SystemEventListenerService);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setSystemEventListener", "setSystemEventListener0", "(Lorg/drools/SystemEventListener;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getSystemEventListener", "getSystemEventListener1", "()Lorg/drools/SystemEventListener;"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__PropertiesConfiguration);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setProperty", "setProperty0", "(Ljava/lang/String;Ljava/lang/String;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getProperty", "getProperty1", "(Ljava/lang/String;)Ljava/lang/String;"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__NodeInstanceContainer);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getNodeInstances", "getNodeInstances0", "()Ljava/util/Collection;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getNodeInstance", "getNodeInstance1", "(J)Lorg/drools/runtime/process/NodeInstance;"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__RuleFlowGroup);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "clear", "clear0", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getName", "getName1", "()Ljava/lang/String;"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__EventListener);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "signalEvent", "signalEvent0", "(Ljava/lang/String;Ljava/lang/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getEventTypes", "getEventTypes1", "()[Ljava/lang/String;"));
     return methods;
 }
示例#14
0
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__Operator);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getOperatorString", "getOperatorString0", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isNegated", "isNegated1", "()Z"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__IDebugProperty);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getValue", "getValue0", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getKey", "getKey1", "()Ljava/lang/String;"));
     return methods;
 }
示例#16
0
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__Resource);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getInputStream", "getInputStream0", "()Ljava/io/InputStream;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getReader", "getReader1", "()Ljava/io/Reader;"));
     return methods;
 }
示例#17
0
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__Evaluator);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getOperator", "getOperator0", "()Lorg/drools/runtime/rule/Operator;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isTemporal", "isTemporal1", "()Z"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__DroolsManagementAgentMBean);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getKnowledgeBaseCount", "getKnowledgeBaseCount0", "()J"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getSessionCount", "getSessionCount1", "()J"));
     return methods;
 }
示例#19
0
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__Row);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "get", "get0", "(Ljava/lang/String;)Ljava/lang/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getFactHandle", "getFactHandle1", "(Ljava/lang/String;)Lorg/drools/runtime/rule/FactHandle;"));
     return methods;
 }
示例#20
0
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__WildcardType);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getLowerBounds", "getLowerBounds0", "()[Ljava/lang/reflect/Type;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getUpperBounds", "getUpperBounds1", "()[Ljava/lang/reflect/Type;"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__StatelessRuleSession);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "execute", "execute0", "(Ljava/lang/Iterable;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "execute", "execute1", "(Ljava/lang/Object;)V"));
     return methods;
 }
示例#22
0
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__Appendable);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "append", "append0", "(Ljava/lang/CharSequence;II)Ljava/lang/Appendable;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "append", "append1", "(C)Ljava/lang/Appendable;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "append", "append2", "(Ljava/lang/CharSequence;)Ljava/lang/Appendable;"));
     return methods;
 }
示例#23
0
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__TypeVariable);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getName", "getName0", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getBounds", "getBounds1", "()[Ljava/lang/reflect/Type;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getGenericDeclaration", "getGenericDeclaration2", "()Ljava/lang/reflect/GenericDeclaration;"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__ParameterizedType);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getActualTypeArguments", "getActualTypeArguments0", "()[Ljava/lang/reflect/Type;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getOwnerType", "getOwnerType1", "()Ljava/lang/reflect/Type;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getRawType", "getRawType2", "()Ljava/lang/reflect/Type;"));
     return methods;
 }
示例#25
0
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__IJvmProxy);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getJvmHandle", "JvmHandle0", "()J"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Init", "Init2", "(Lsystem/Object;J)V"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__ActivationCancelledEvent);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getKnowledgeRuntime", "getKnowledgeRuntime0", "()Lorg/drools/runtime/KnowledgeRuntime;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getActivation", "getActivation1", "()Lorg/drools/runtime/rule/Activation;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCause", "getCause2", "()Lorg/drools/event/rule/ActivationCancelledCause;"));
     return methods;
 }
示例#27
0
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__Enumeration);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "hasMoreElements", "hasMoreElements0", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "nextElement", "nextElement1", "()Ljava/lang/Object;"));
     return methods;
 }
示例#28
0
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv env, global::java.lang.Class clazz)
 {
     global::System.Type type = typeof(__IClrProxy);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(type, "getClrHandle", "getClrHandle0", "()J"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(type, "initProxy", "initProxy1", "(J)V"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class) {
     global::System.Type @__type = typeof(__QueryResults);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "iterator", "iterator0", "()Ljava/util/Iterator;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "size", "size1", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getIdentifiers", "getIdentifiers2", "()[Ljava/lang/String;"));
     return methods;
 }
 private static global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__SystemException);
     global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List<global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorSystemException0", "__ctorSystemException0", "(Lnet/sf/jni4net/inj/IClrProxy;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorSystemException1", "__ctorSystemException1", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorSystemException2", "__ctorSystemException2", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;Lsystem/Exception;)V"));
     return methods;
 }
示例#31
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__Set);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "add", "add0", "(Ljava/lang/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "remove", "remove1", "(Ljava/lang/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "equals", "equals2", "(Ljava/lang/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "hashCode", "hashCode3", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "clear", "clear4", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "contains", "contains5", "(Ljava/lang/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isEmpty", "isEmpty6", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "iterator", "iterator7", "()Ljava/util/Iterator;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "size", "size8", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "toArray", "toArray9", "()[Ljava/lang/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "toArray", "toArray10", "([Ljava/lang/Object;)[Ljava/lang/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "spliterator", "spliterator11", "()Ljava/util/Spliterator;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "addAll", "addAll12", "(Ljava/util/Collection;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "containsAll", "containsAll13", "(Ljava/util/Collection;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "removeAll", "removeAll14", "(Ljava/util/Collection;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "retainAll", "retainAll15", "(Ljava/util/Collection;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "stream", "stream16", "()Ljava/util/stream/Stream;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "removeIf", "removeIf17", "(Ljava/util/function/Predicate;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "parallelStream", "parallelStream18", "()Ljava/util/stream/Stream;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "forEach", "forEach19", "(Ljava/util/function/Consumer;)V"));
     return(methods);
 }
示例#32
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__FileStream);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isAsync", "IsAsync0", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getName", "Name1", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetAccessControl", "GetAccessControl2", "()Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "SetAccessControl", "SetAccessControl3", "(Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Flush", "Flush4", "(Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getHandle", "Handle5", "()J"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getSafeFileHandle", "SafeFileHandle6", "()Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Lock", "Lock7", "(JJ)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Unlock", "Unlock8", "(JJ)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream0", "__ctorFileStream0", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;Lsystem/Enum;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream1", "__ctorFileStream1", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;Lsystem/Enum;Lsystem/Enum;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream2", "__ctorFileStream2", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;Lsystem/Enum;Lsystem/Enum;Lsyste" +
                                                                   "m/Enum;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream3", "__ctorFileStream3", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;Lsystem/Enum;Lsystem/Enum;Lsyste" +
                                                                   "m/Enum;I)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream4", "__ctorFileStream4", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;Lsystem/Enum;Lsystem/Enum;Lsyste" +
                                                                   "m/Enum;ILsystem/Enum;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream5", "__ctorFileStream5", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;Lsystem/Enum;Lsystem/Enum;Lsyste" +
                                                                   "m/Enum;IZ)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream6", "__ctorFileStream6", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;Lsystem/Enum;Lsystem/Enum;Lsyste" +
                                                                   "m/Enum;ILsystem/Enum;Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream7", "__ctorFileStream7", "(Lnet/sf/jni4net/inj/IClrProxy;JLsystem/Enum;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream8", "__ctorFileStream8", "(Lnet/sf/jni4net/inj/IClrProxy;JLsystem/Enum;Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream9", "__ctorFileStream9", "(Lnet/sf/jni4net/inj/IClrProxy;JLsystem/Enum;ZI)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream10", "__ctorFileStream10", "(Lnet/sf/jni4net/inj/IClrProxy;JLsystem/Enum;ZIZ)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream11", "__ctorFileStream11", "(Lnet/sf/jni4net/inj/IClrProxy;Lsystem/Object;Lsystem/Enum;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream12", "__ctorFileStream12", "(Lnet/sf/jni4net/inj/IClrProxy;Lsystem/Object;Lsystem/Enum;I)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorFileStream13", "__ctorFileStream13", "(Lnet/sf/jni4net/inj/IClrProxy;Lsystem/Object;Lsystem/Enum;IZ)V"));
     return(methods);
 }
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__ResourceFactoryService);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getResourceChangeNotifierService", "getResourceChangeNotifierService0", "()Lorg/drools/io/ResourceChangeNotifier;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getResourceChangeScannerService", "getResourceChangeScannerService1", "()Lorg/drools/io/ResourceChangeScanner;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "newUrlResource", "newUrlResource2", "(Ljava/lang/String;)Lorg/drools/io/Resource;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "newUrlResource", "newUrlResource3", "(Ljava/net/URL;)Lorg/drools/io/Resource;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "newFileSystemResource", "newFileSystemResource4", "(Ljava/lang/String;)Lorg/drools/io/Resource;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "newFileSystemResource", "newFileSystemResource5", "(Ljava/io/File;)Lorg/drools/io/Resource;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "newByteArrayResource", "newByteArrayResource6", "([B)Lorg/drools/io/Resource;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "newInputStreamResource", "newInputStreamResource7", "(Ljava/io/InputStream;)Lorg/drools/io/Resource;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "newReaderResource", "newReaderResource8", "(Ljava/io/Reader;Ljava/lang/String;)Lorg/drools/io/Resource;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "newReaderResource", "newReaderResource9", "(Ljava/io/Reader;)Lorg/drools/io/Resource;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "newClassPathResource", "newClassPathResource10", "(Ljava/lang/String;Ljava/lang/ClassLoader;)Lorg/drools/io/Resource;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "newClassPathResource", "newClassPathResource11", "(Ljava/lang/String;Ljava/lang/Class;)Lorg/drools/io/Resource;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "newClassPathResource", "newClassPathResource12", "(Ljava/lang/String;)Lorg/drools/io/Resource;"));
     return(methods);
 }
示例#34
0
        public unsafe void ControlMsg(bool useMultipleControlMessages)
        {
            // Create two socket pairs and send inner_so1 and inner_so2 over the other socket pair using SCM_RIGHTS
            WithSocketPair((inner_so1, inner_so2) => {
                WithSocketPair((so1, so2) => {
                    byte[] cmsg;
                    Msghdr msghdr1;
                    long offset;
                    if (useMultipleControlMessages)
                    {
                        // Create two SCM_RIGHTS control messages
                        cmsg    = new byte[2 * Syscall.CMSG_SPACE(sizeof(int))];
                        var hdr = new Cmsghdr {
                            cmsg_len   = (long)Syscall.CMSG_LEN(sizeof(int)),
                            cmsg_level = UnixSocketProtocol.SOL_SOCKET,
                            cmsg_type  = UnixSocketControlMessage.SCM_RIGHTS,
                        };
                        msghdr1 = new Msghdr {
                            msg_control    = cmsg,
                            msg_controllen = cmsg.Length,
                        };
                        offset = 0;
                        hdr.WriteToBuffer(msghdr1, offset);
                        var dataOffset  = Syscall.CMSG_DATA(msghdr1, offset);
                        fixed(byte *ptr = msghdr1.msg_control)
                        {
                            ((int *)(ptr + dataOffset))[0] = inner_so1;
                        }
                        offset = (long)Syscall.CMSG_SPACE(sizeof(int));
                        hdr.WriteToBuffer(msghdr1, offset);
                        dataOffset      = Syscall.CMSG_DATA(msghdr1, offset);
                        fixed(byte *ptr = msghdr1.msg_control)
                        {
                            ((int *)(ptr + dataOffset))[0] = inner_so2;
                        }
                    }
                    else
                    {
                        // Create one SCM_RIGHTS control message
                        cmsg    = new byte[Syscall.CMSG_SPACE(2 * sizeof(int))];
                        var hdr = new Cmsghdr {
                            cmsg_len   = (long)Syscall.CMSG_LEN(2 * sizeof(int)),
                            cmsg_level = UnixSocketProtocol.SOL_SOCKET,
                            cmsg_type  = UnixSocketControlMessage.SCM_RIGHTS,
                        };
                        msghdr1 = new Msghdr {
                            msg_control    = cmsg,
                            msg_controllen = cmsg.Length,
                        };
                        offset = 0;
                        hdr.WriteToBuffer(msghdr1, offset);
                        var dataOffset  = Syscall.CMSG_DATA(msghdr1, offset);
                        fixed(byte *ptr = msghdr1.msg_control)
                        {
                            ((int *)(ptr + dataOffset))[0] = inner_so1;
                            ((int *)(ptr + dataOffset))[1] = inner_so2;
                        }
                    }

                    long ret;
                    var buffer1             = new byte[] { 42, 43, 44 };
                    fixed(byte *ptr_buffer1 = buffer1)
                    {
                        var iovecs1 = new Iovec[] {
                            new Iovec {
                                iov_base = (IntPtr)ptr_buffer1,
                                iov_len  = (ulong)buffer1.Length,
                            },
                        };
                        msghdr1.msg_iov    = iovecs1;
                        msghdr1.msg_iovlen = 1;
                        // Send message twice
                        ret = Syscall.sendmsg(so1, msghdr1, 0);
                        if (ret < 0)
                        {
                            UnixMarshal.ThrowExceptionForLastError();
                        }
                        ret = Syscall.sendmsg(so1, msghdr1, 0);
                        if (ret < 0)
                        {
                            UnixMarshal.ThrowExceptionForLastError();
                        }
                    }

                    // Receive without control message buffer
                    var buffer2             = new byte[1024];
                    var msghdr2             = new Msghdr {
                    };
                    fixed(byte *ptr_buffer2 = buffer2)
                    {
                        var iovecs2 = new Iovec[] {
                            new Iovec {
                                iov_base = (IntPtr)ptr_buffer2,
                                iov_len  = (ulong)buffer2.Length,
                            },
                        };
                        msghdr2.msg_iov    = iovecs2;
                        msghdr2.msg_iovlen = 1;
                        ret = Syscall.recvmsg(so2, msghdr2, 0);
                    }
                    if (ret < 0)
                    {
                        UnixMarshal.ThrowExceptionForLastError();
                    }

                    if (useMultipleControlMessages)                                        // This assertion fails on OSX for some reason
                    {
                        Assert.IsTrue((msghdr2.msg_flags & MessageFlags.MSG_CTRUNC) != 0); // Control message has been truncated
                    }
                    Assert.AreEqual(buffer1.Length, ret);
                    for (int i = 0; i < buffer1.Length; i++)
                    {
                        Assert.AreEqual(buffer1[i], buffer2[i]);
                    }

                    // Receive with control message buffer
                    buffer2   = new byte[1024];
                    var cmsg2 = new byte[1024];
                    msghdr2   = new Msghdr {
                        msg_control    = cmsg2,
                        msg_controllen = cmsg2.Length,
                    };
                    fixed(byte *ptr_buffer2 = buffer2)
                    {
                        var iovecs2 = new Iovec[] {
                            new Iovec {
                                iov_base = (IntPtr)ptr_buffer2,
                                iov_len  = (ulong)buffer2.Length,
                            },
                        };
                        msghdr2.msg_iov    = iovecs2;
                        msghdr2.msg_iovlen = 1;
                        ret = Syscall.recvmsg(so2, msghdr2, 0);
                    }
                    if (ret < 0)
                    {
                        UnixMarshal.ThrowExceptionForLastError();
                    }

                    var fds = new global::System.Collections.Generic.List <int> ();
                    for (offset = Syscall.CMSG_FIRSTHDR(msghdr2); offset != -1; offset = Syscall.CMSG_NXTHDR(msghdr2, offset))
                    {
                        var recvHdr        = Cmsghdr.ReadFromBuffer(msghdr2, offset);
                        var recvDataOffset = Syscall.CMSG_DATA(msghdr2, offset);
                        var bytes          = recvHdr.cmsg_len - (recvDataOffset - offset);
                        Assert.AreEqual(bytes % sizeof(int), 0);
                        var fdCount     = bytes / sizeof(int);
                        fixed(byte *ptr = msghdr2.msg_control)
                        for (int i = 0; i < fdCount; i++)
                        {
                            fds.Add(((int *)(ptr + recvDataOffset))[i]);
                        }
                    }
                    try {
                        Assert.IsTrue((msghdr2.msg_flags & MessageFlags.MSG_CTRUNC) == 0);                          // Control message has not been truncated

                        Assert.AreEqual(buffer1.Length, ret);
                        for (int i = 0; i < buffer1.Length; i++)
                        {
                            Assert.AreEqual(buffer1[i], buffer2[i]);
                        }

                        Assert.AreEqual(fds.Count, 2);

                        // Send message over the first received fd and receive it over inner_so2
                        var buffer3 = new byte[] { 16, 17 };
                        ret         = Syscall.send(fds[0], buffer3, (ulong)buffer3.Length, 0);
                        if (ret < 0)
                        {
                            UnixMarshal.ThrowExceptionForLastError();
                        }

                        var buffer4 = new byte[1024];
                        ret         = Syscall.recv(inner_so2, buffer4, (ulong)buffer4.Length, 0);
                        if (ret < 0)
                        {
                            UnixMarshal.ThrowExceptionForLastError();
                        }

                        Assert.AreEqual(buffer3.Length, ret);
                        for (int i = 0; i < buffer3.Length; i++)
                        {
                            Assert.AreEqual(buffer3[i], buffer4[i]);
                        }

                        // Send message over inner_so1 and receive it second received fd
                        var buffer5 = new byte[] { 10, 40, 0, 1 };
                        ret         = Syscall.send(inner_so1, buffer5, (ulong)buffer5.Length, 0);
                        if (ret < 0)
                        {
                            UnixMarshal.ThrowExceptionForLastError();
                        }

                        var buffer6 = new byte[1024];
                        ret         = Syscall.recv(fds[1], buffer6, (ulong)buffer6.Length, 0);
                        if (ret < 0)
                        {
                            UnixMarshal.ThrowExceptionForLastError();
                        }

                        Assert.AreEqual(buffer5.Length, ret);
                        for (int i = 0; i < buffer5.Length; i++)
                        {
                            Assert.AreEqual(buffer5[i], buffer6[i]);
                        }
                    } finally {
                        foreach (var fd in fds)
                        {
                            if (Syscall.close(fd) < 0)
                            {
                                UnixMarshal.ThrowExceptionForLastError();
                            }
                        }
                    }
                });
            });
        }
示例#35
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__MethodBase);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetParameters", "GetParameters0", "()[Lsystem/reflection/ParameterInfo;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetMethodImplementationFlags", "GetMethodImplementationFlags1", "()Lsystem/Enum;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getMethodHandle", "MethodHandle2", "()Lsystem/ValueType;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getAttributes", "Attributes3", "()Lsystem/Enum;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCallingConvention", "CallingConvention4", "()Lsystem/Enum;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Invoke", "Invoke5", "(Lsystem/Object;Lsystem/reflection/BindingFlags;Lsystem/Object;[Lsystem/Object;Ls" +
                                                                   "ystem/Object;)Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isPublic", "IsPublic6", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isPrivate", "IsPrivate7", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isFamily", "IsFamily8", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isAssembly", "IsAssembly9", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isFamilyAndAssembly", "IsFamilyAndAssembly10", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isFamilyOrAssembly", "IsFamilyOrAssembly11", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isStatic", "IsStatic12", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isFinal", "IsFinal13", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isVirtual", "IsVirtual14", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isHideBySig", "IsHideBySig15", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isAbstract", "IsAbstract16", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isSpecialName", "IsSpecialName17", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isConstructor", "IsConstructor18", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Invoke", "Invoke19", "(Lsystem/Object;[Lsystem/Object;)Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetMethodFromHandle", "GetMethodFromHandle20", "(Lsystem/ValueType;)Lsystem/reflection/MethodBase;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetMethodFromHandle", "GetMethodFromHandle21", "(Lsystem/ValueType;Lsystem/ValueType;)Lsystem/reflection/MethodBase;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetCurrentMethod", "GetCurrentMethod22", "()Lsystem/reflection/MethodBase;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetGenericArguments", "GetGenericArguments23", "()[Lsystem/Type;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isGenericMethodDefinition", "IsGenericMethodDefinition24", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getContainsGenericParameters", "ContainsGenericParameters25", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isGenericMethod", "IsGenericMethod26", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetMethodBody", "GetMethodBody27", "()Lsystem/Object;"));
     return(methods);
 }
示例#36
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__StatelessKnowledgeSession);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "execute", "execute0", "(Ljava/lang/Iterable;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "execute", "execute1", "(Ljava/lang/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "execute", "execute2", "(Lorg/drools/command/Command;)Ljava/lang/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "addEventListener", "addEventListener3", "(Lorg/drools/event/rule/AgendaEventListener;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "addEventListener", "addEventListener4", "(Lorg/drools/event/rule/WorkingMemoryEventListener;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "removeEventListener", "removeEventListener5", "(Lorg/drools/event/rule/AgendaEventListener;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "removeEventListener", "removeEventListener6", "(Lorg/drools/event/rule/WorkingMemoryEventListener;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getWorkingMemoryEventListeners", "getWorkingMemoryEventListeners7", "()Ljava/util/Collection;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getAgendaEventListeners", "getAgendaEventListeners8", "()Ljava/util/Collection;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "addEventListener", "addEventListener9", "(Lorg/drools/event/process/ProcessEventListener;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "removeEventListener", "removeEventListener10", "(Lorg/drools/event/process/ProcessEventListener;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getProcessEventListeners", "getProcessEventListeners11", "()Ljava/util/Collection;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setGlobal", "setGlobal12", "(Ljava/lang/String;Ljava/lang/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getGlobals", "getGlobals13", "()Lorg/drools/runtime/Globals;"));
     return(methods);
 }
示例#37
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__HECRASGeometryClass);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "nRiver", "nRiver0", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "RiverName", "RiverName1", "(Lnet/sf/jni4net/Ref;)Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "RiverIndex", "RiverIndex2", "(Lnet/sf/jni4net/Ref;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "nReach", "nReach3", "(Lnet/sf/jni4net/Ref;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ReachName", "ReachName4", "(Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;)Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ReachIndex", "ReachIndex5", "(Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ReachInvert_nPoints", "ReachInvert_nPoints6", "(Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ReachInvert_Points", "ReachInvert_Points7", "(Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;" +
                                                                   ")V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "nNode", "nNode8", "(Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "NodeRS", "NodeRS9", "(Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;)Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "NodeIndex", "NodeIndex10", "(Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "NodeType", "NodeType11", "(Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "NodeCType", "NodeCType12", "(Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;)Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "NodeCutLine_nPoints", "NodeCutLine_nPoints13", "(Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "NodeCutLine_Points", "NodeCutLine_Points14", "(Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;Lnet/sf/jni4net/Ref;" +
                                                                   "Lnet/sf/jni4net/Ref;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Save", "Save15", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHECRASGeometryClass0", "__ctorHECRASGeometryClass0", "(Lnet/sf/jni4net/inj/IClrProxy;)V"));
     return(methods);
 }
示例#38
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__Map);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "hashCode", "hashCode0", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "put", "put1", "(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "clear", "clear2", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "equals", "equals3", "(Ljava/lang/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "entrySet", "entrySet4", "()Ljava/util/Set;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "get", "get5", "(Ljava/lang/Object;)Ljava/lang/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "putAll", "putAll6", "(Ljava/util/Map;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "size", "size7", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "values", "values8", "()Ljava/util/Collection;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "remove", "remove9", "(Ljava/lang/Object;)Ljava/lang/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "containsKey", "containsKey10", "(Ljava/lang/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "containsValue", "containsValue11", "(Ljava/lang/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isEmpty", "isEmpty12", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "keySet", "keySet13", "()Ljava/util/Set;"));
     return(methods);
 }
        /// <summary>
        /// Adds a row lock to the list of locks that must be released at the end of a transaction.
        /// </summary>
        /// <param name="enlistment">Facilitates communication bewtween an enlisted transaction participant and the transaction
        /// manager during the final phase of the transaction.</param>
        public void Commit(global::System.Transactions.Enlistment enlistment)
        {
            try
            {
                global::System.Collections.Generic.List <object> transactionLogItem = new global::System.Collections.Generic.List <object>();
                DataModel.TransactionLogLock.EnterWriteLock();
                DataModel.DataLock.EnterWriteLock();
                for (int recordIndex = 0; (recordIndex < this.recordList.Count); recordIndex = (recordIndex + 1))
                {
                    global::FluidTrade.Core.IRow   iRow   = this.recordList[recordIndex];
                    global::FluidTrade.Core.ITable iTable = ((global::FluidTrade.Core.ITable)(iRow.Table));
                    if ((iRow.RowState == global::System.Data.DataRowState.Modified))
                    {
                        transactionLogItem.Clear();
                        transactionLogItem.Add(global::FluidTrade.Core.RecordState.Modified);
                        transactionLogItem.Add(iTable.Ordinal);
                        for (int keyIndex = 0; (keyIndex < iTable.PrimaryKey.Length); keyIndex = (keyIndex + 1))
                        {
                            transactionLogItem.Add(iRow[iTable.PrimaryKey[keyIndex]]);
                        }
                        for (int columnIndex = 0; (columnIndex < iTable.Columns.Count); columnIndex = (columnIndex + 1))
                        {
                            if ((iRow[columnIndex].Equals(iRow[columnIndex, global::System.Data.DataRowVersion.Original]) == false))
                            {
                                transactionLogItem.Add(columnIndex);
                                transactionLogItem.Add(iRow[columnIndex]);
                            }
                        }
                        DataModel.AddTransaction(iRow, transactionLogItem.ToArray());
                        iRow.AcceptChanges();
                    }
                    else
                    {
                        if ((iRow.RowState == global::System.Data.DataRowState.Added))
                        {
                            transactionLogItem.Clear();
                            transactionLogItem.Add(global::FluidTrade.Core.RecordState.Added);
                            transactionLogItem.Add(iTable.Ordinal);
                            for (int keyIndex = 0; (keyIndex < iTable.PrimaryKey.Length); keyIndex = (keyIndex + 1))
                            {
                                transactionLogItem.Add(iRow[iTable.PrimaryKey[keyIndex]]);
                            }
                            for (int columnIndex = 0; (columnIndex < iTable.Columns.Count); columnIndex = (columnIndex + 1))
                            {
                                if ((iRow[columnIndex].Equals(iTable.Columns[columnIndex].DefaultValue) == false))
                                {
                                    transactionLogItem.Add(columnIndex);
                                    transactionLogItem.Add(iRow[columnIndex]);
                                }
                            }
                            DataModel.AddTransaction(iRow, transactionLogItem.ToArray());
                            iRow.AcceptChanges();
                        }
                        else
                        {
                            transactionLogItem.Clear();
                            transactionLogItem.Add(global::FluidTrade.Core.RecordState.Deleted);
                            transactionLogItem.Add(iTable.Ordinal);
                            for (int keyIndex = 0; (keyIndex < iTable.PrimaryKey.Length); keyIndex = (keyIndex + 1))
                            {
                                transactionLogItem.Add(iRow[iTable.PrimaryKey[keyIndex], global::System.Data.DataRowVersion.Original]);
                            }
                            DataModel.AddTransaction(iRow, transactionLogItem.ToArray());
                            iRow.AcceptChanges();
                        }
                    }
                }
            }
            finally
            {
                ClearRowLockList();

                DataModel.TransactionLogLock.ExitWriteLock();
                DataModel.DataLock.ExitWriteLock();

                try
                {
                    //txn is done remove this txn from the threads stack
                    //in theory the stack should only be accessed from the same thread so dont need a lock
                    //although might want to look at the stack through the DataModelTransaction
                    //via another thread. so lock just to be safe
                    lock (this.dataModelTransactionStack)
                        this.dataModelTransactionStack.Pop();
                }
                catch (Exception ex)
                {
                    try
                    {
                        global::FluidTrade.Core.EventLog.Information("Error in Commit dataModelTransactionStack.Pop {0}\r\n{1}", ex.Message, ex.StackTrace);
                    }
                    catch
                    {
                    }
                }
            }
            enlistment.Done();
        }
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__WorkingMemoryEntryPoint);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getObject", "getObject0", "(Lorg/drools/runtime/rule/FactHandle;)Ljava/lang/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "insert", "insert1", "(Ljava/lang/Object;)Lorg/drools/runtime/rule/FactHandle;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "update", "update2", "(Lorg/drools/runtime/rule/FactHandle;Ljava/lang/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getFactHandle", "getFactHandle3", "(Ljava/lang/Object;)Lorg/drools/runtime/rule/FactHandle;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getEntryPointId", "getEntryPointId4", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "retract", "retract5", "(Lorg/drools/runtime/rule/FactHandle;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getObjects", "getObjects6", "(Lorg/drools/runtime/ObjectFilter;)Ljava/util/Collection;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getObjects", "getObjects7", "()Ljava/util/Collection;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getFactHandles", "getFactHandles8", "(Lorg/drools/runtime/ObjectFilter;)Ljava/util/Collection;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getFactHandles", "getFactHandles9", "()Ljava/util/Collection;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getFactCount", "getFactCount10", "()J"));
     return(methods);
 }
示例#41
0
        global::System.Object Read1_Object(bool isNullable, bool checkType, string defaultNamespace = null)
        {
            System.Xml.XmlQualifiedName xsiType = checkType ? GetXsiType() : null;
            bool isNull = false;

            if (isNullable)
            {
                isNull = ReadNull();
            }
            if (checkType)
            {
                if (isNull)
                {
                    if (xsiType != null)
                    {
                        return((global::System.Object)ReadTypedNull(xsiType));
                    }
                    else
                    {
                        return(null);
                    }
                }
                if (xsiType == null)
                {
                    return(ReadTypedPrimitive(new System.Xml.XmlQualifiedName("anyType", "http://www.w3.org/2001/XMLSchema")));
                }
                else if (((object)((System.Xml.XmlQualifiedName)xsiType).Name == (object)id3_PersistModel && string.Equals(((System.Xml.XmlQualifiedName)xsiType).Namespace, defaultNamespace ?? id2_Item)))
                {
                    return(Read2_PersistModel(isNullable, false, defaultNamespace));
                }
                else if (((object)((System.Xml.XmlQualifiedName)xsiType).Name == (object)id1_ArrayOfPersistModel && string.Equals(((System.Xml.XmlQualifiedName)xsiType).Namespace, defaultNamespace ?? id2_Item)))
                {
                    global::System.Collections.Generic.List <global::NavigationMenuSample.Models.PersistModel> a = null;
                    if (!ReadNull())
                    {
                        if ((object)(a) == null)
                        {
                            a = new global::System.Collections.Generic.List <global::NavigationMenuSample.Models.PersistModel>();
                        }
                        global::System.Collections.Generic.List <global::NavigationMenuSample.Models.PersistModel> z_0_0 = (global::System.Collections.Generic.List <global::NavigationMenuSample.Models.PersistModel>)a;
                        if ((Reader.IsEmptyElement))
                        {
                            Reader.Skip();
                        }
                        else
                        {
                            Reader.ReadStartElement();
                            Reader.MoveToContent();
                            int whileIterations1 = 0;
                            int readerCount1     = ReaderCount;
                            while (Reader.NodeType != System.Xml.XmlNodeType.EndElement && Reader.NodeType != System.Xml.XmlNodeType.None)
                            {
                                if (Reader.NodeType == System.Xml.XmlNodeType.Element)
                                {
                                    if (((object)Reader.LocalName == (object)id3_PersistModel && string.Equals(Reader.NamespaceURI, defaultNamespace ?? id2_Item)))
                                    {
                                        if ((object)(z_0_0) == null)
                                        {
                                            Reader.Skip();
                                        }
                                        else
                                        {
                                            z_0_0.Add(Read2_PersistModel(true, true, defaultNamespace));
                                        }
                                    }
                                    else
                                    {
                                        UnknownNode(null, @":PersistModel");
                                    }
                                }
                                else
                                {
                                    UnknownNode(null, @":PersistModel");
                                }
                                Reader.MoveToContent();
                                CheckReaderCount(ref whileIterations1, ref readerCount1);
                            }
                            ReadEndElement();
                        }
                    }
                    return(a);
                }
                else
                {
                    return(ReadTypedPrimitive((System.Xml.XmlQualifiedName)xsiType));
                }
            }
            if (isNull)
            {
                return(null);
            }
            global::System.Object o;
            o = new global::System.Object();
            bool[] paramsRead = new bool[0];
            while (Reader.MoveToNextAttribute())
            {
                if (!IsXmlnsAttribute(Reader.Name))
                {
                    UnknownNode((object)o);
                }
            }
            Reader.MoveToElement();
            if (Reader.IsEmptyElement)
            {
                Reader.Skip();
                return(o);
            }
            Reader.ReadStartElement();
            Reader.MoveToContent();
            int whileIterations2 = 0;
            int readerCount2     = ReaderCount;

            while (Reader.NodeType != System.Xml.XmlNodeType.EndElement && Reader.NodeType != System.Xml.XmlNodeType.None)
            {
                if (Reader.NodeType == System.Xml.XmlNodeType.Element)
                {
                    UnknownNode((object)o, @"");
                }
                else
                {
                    UnknownNode((object)o, @"");
                }
                Reader.MoveToContent();
                CheckReaderCount(ref whileIterations2, ref readerCount2);
            }
            ReadEndElement();
            return(o);
        }
示例#42
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__Guid);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ToString", "ToString0", "(Ljava/lang/String;Lsystem/IFormatProvider;)Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "CompareTo", "CompareTo1", "(Lsystem/Object;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "CompareTo", "CompareTo2", "(Lsystem/Guid;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Equals", "Equals3", "(Lsystem/Guid;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Parse", "Parse4", "(Ljava/lang/String;)Lsystem/Guid;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "TryParse", "TryParse5", "(Ljava/lang/String;Lnet/sf/jni4net/Out;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ParseExact", "ParseExact6", "(Ljava/lang/String;Ljava/lang/String;)Lsystem/Guid;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "TryParseExact", "TryParseExact7", "(Ljava/lang/String;Ljava/lang/String;Lnet/sf/jni4net/Out;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ToByteArray", "ToByteArray8", "()[B"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "NewGuid", "NewGuid9", "()Lsystem/Guid;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ToString", "ToString10", "(Ljava/lang/String;)Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorGuid0", "__ctorGuid0", "(Lnet/sf/jni4net/inj/IClrProxy;[B)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorGuid1", "__ctorGuid1", "(Lnet/sf/jni4net/inj/IClrProxy;ISSBBBBBBBB)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorGuid2", "__ctorGuid2", "(Lnet/sf/jni4net/inj/IClrProxy;ISS[B)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorGuid3", "__ctorGuid3", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;)V"));
     return(methods);
 }
示例#43
0
        //public const string Alias = "Class1";
        //public const string DefaultData = "Class1Data";


        /// <summary>
        /// Creates a new control
        /// </summary>
        /// <param name="DataElement">The hidden data element</param>
        public SimpleRollover()
        {
            // wallpapers at http://labnol.blogspot.com/2006/11/download-windows-vista-wallpapers.html

            // * broken at the moment
            #region AnimateCharacterColors
            System.Func <string, INode> AnimateCharacterColors =
                (text) =>
            {
                var s = new IHTMLSpan();

                var l = new global::System.Collections.Generic.List <IHTMLSpan>();

                foreach (char c in text)
                {
                    var y = new string(c, 1);
                    var x = new IHTMLSpan(y);

                    if (y == " ")
                    {
                        s.appendChild(" ");
                    }
                    else
                    {
                        l.Add(x);


                        s.appendChild(x);
                    }
                }



                new Timer(
                    t =>
                {
                    var len = l.Count + 40;

                    if (t.Counter % len < l.Count)
                    {
                        if (t.Counter % (len * 2) < l.Count)
                        {
                            l[t.Counter % len].style.visibility = IStyle.VisibilityEnum.hidden;
                        }
                        else
                        {
                            l[t.Counter % len].style.visibility = IStyle.VisibilityEnum.visible;
                        }
                    }
                }, 6000, 200);


                return(s);
            };
            #endregion
            // */

            var u = new IHTMLDiv();

            //u.style.backgroundColor = Color.Green;
            u.style.position = IStyle.PositionEnum.absolute;
            u.style.left     = "0";
            u.style.top      = "0";
            u.style.height   = "100%";
            u.style.width    = "100%";
            u.style.overflow = IStyle.OverflowEnum.auto;

            var styles = new XStyles
            {
                dark         = new IStyleSheet(),
                light        = new IStyleSheet(),
                switchbutton = new IHTMLAnchor("", "day/night"),
                counter      = 0
            };



            styles.switchbutton.onclick +=
                ev =>
            {
                ev.PreventDefault();

                styles.counter++;


                if (styles.counter % 2 == 1)
                {
                    styles.dark.disabled  = false;
                    styles.light.disabled = true;
                }
                else
                {
                    styles.dark.disabled  = true;
                    styles.light.disabled = false;
                }
            };


            var ad = new IHTMLDiv(
                new IHTMLSpan(
                    AnimateCharacterColors(
                        "this application was written in c# and then translated to javascript by jsc to run in your browser"
                        )
                    ),
                new IHTMLAnchor("http://zproxy.wordpress.com", "visit blog"),
                new IHTMLAnchor("http://jsc.sf.net", "get more examples"),
                styles.switchbutton
                )
            {
                className = "ad1"
            };

            u.appendChild(ad);

            var sheet = new IStyleSheet();

            sheet.AddRule(".ad1",
                          r =>
            {
                r.style.marginTop  = "1em";
                r.style.color      = Color.White;
                r.style.fontFamily = IStyle.FontFamilyEnum.Verdana;
            }
                          );


            sheet.AddRule(".ad1 > *",
                          r =>
            {
                r.style.padding = "1em";

                r.style.marginTop = "1em";
            }
                          );

            sheet.AddRule(".ad1 > span",
                          r =>
            {
                r.style.Float = IStyle.FloatEnum.right;
            }
                          );

            sheet.AddRule(".ad1 > a",
                          r =>
            {
                r.style.Float = IStyle.FloatEnum.left;
                r.style.color = Color.White;

                r.style.textDecoration = "none";
            }
                          );

            sheet.AddRule(".ad1 a:hover",
                          r =>
            {
                r.style.color = Color.Yellow;
            }
                          );



            sheet.AddRule("html",
                          r =>
            {
                r.style.overflow = IStyle.OverflowEnum.hidden;
            }
                          );

            sheet.AddRule("body",
                          r =>
            {
                r.style.overflow = IStyle.OverflowEnum.hidden;

                r.style.padding = "0";
                r.style.margin  = "0";

                //r.style.backgroundImage = "url(assets/vista.jpg)";
            }
                          );


            styles.dark.AddRule("body").style.backgroundColor    = JSColor.Black;
            styles.dark.AddRule("body").style.backgroundPosition = "center top";

            styles.light.AddRule("body").style.backgroundColor    = JSColor.Black;
            styles.light.AddRule("body").style.backgroundPosition = "center top";


            new global::SimpleRollover.HTML.Images.FromAssets.vistax().ToBackground(
                styles.dark.AddRule("body").style, false
                );

            new global::SimpleRollover.HTML.Images.FromAssets.vista().ToBackground(
                styles.dark.AddRule(".effect1").style
                );

            styles.dark.AddRule(".moon1").style.backgroundColor = Color.Yellow;

            new global::SimpleRollover.HTML.Images.FromAssets.vista().ToBackground(
                styles.light.AddRule("body").style, false
                );

            new global::SimpleRollover.HTML.Images.FromAssets.vistax().ToBackground(
                styles.light.AddRule(".effect1").style
                );
            styles.light.AddRule(".moon1").style.backgroundColor = Color.Red;


            sheet.AddRule(".special1",
                          r =>
            {
                r.style.background = "none";
                r.style.border     = "0";
                r.style.width      = "100%";
                r.style.marginTop  = "4em";
            }
                          );

            sheet.AddRule(".content1",
                          r =>
            {
                r.style.backgroundColor = Color.White;

                r.style.padding     = "1em";
                r.style.marginLeft  = "4em";
                r.style.marginRight = "4em";
                r.style.Opacity     = 0.5;
                r.style.border      = "1px solid gray";
            }
                          );

            sheet.AddRule(".special1 img", "border: 0", 0);
            sheet.AddRule(".special1:hover", "background: url(" + new global::SimpleRollover.HTML.Images.FromAssets.Untitled_3().src + ") repeat-x", 1);

            sheet.AddRule(".special1 .hot").style.display       = IStyle.DisplayEnum.none;
            sheet.AddRule(".special1:hover .hot").style.display = IStyle.DisplayEnum.inline;

            sheet.AddRule(".special1 .cold", "display: inline;", 1);
            sheet.AddRule(".special1:hover .cold", "display: none;", 1);


            var states = new XState[] { }.AsEnumerable();

            //    new XState {
            //        Show = default(System.Action),
            //        Hide = default(System.Action),
            //        Selected = false }
            //}.Where(p => false);


            Action <IHTMLImage, IHTMLImage, string> Spawn =
                async(icold, ihot, i2) =>
            {
                var cold = await icold;
                var hot  = await ihot;

                //((IHTMLImage)i[0]).InvokeOnComplete(cold =>
                //((IHTMLImage)i[1]).InvokeOnComplete(hot =>
                //     {
                cold.className = "cold";
                hot.className  = "hot";


                var btn = new IHTMLButton()
                {
                    className = "special1"
                };

                btn.appendChild(cold, hot);

                var content = new IHTMLElement(IHTMLElement.HTMLElementEnum.pre);

                content.innerHTML = "...";
                content.className = "content1";

                var tween     = new TweenDataDouble();
                var tween_max = 16;

                tween.ValueChanged +=
                    delegate
                {
                    content.style.Opacity = tween.Value / tween_max;
                    content.style.height  = tween.Value + "em";

                    content.style.overflow = IStyle.OverflowEnum.hidden;
                };

                tween.Done += delegate
                {
                    if (tween.Value > 0)
                    {
                        content.style.overflow = IStyle.OverflowEnum.auto;
                    }
                };

                tween.Value = 0;

                var state = new XState
                {
                    Show = (System.Action)(() =>
                    {
                        tween.Value = tween_max;
                    }
                                           ),
                    Hide     = (System.Action)(() => tween.Value = 0),
                    Selected = false
                };

                //try
                //{
                //    new IXMLHttpRequest(HTTPMethodEnum.GET, i[2],
                //       request => content.innerHTML = request.responseText
                //    );
                //}
                //catch
                //{
                content.innerText = i2;
                //}

                states = states.Concat(new[] { state });

                btn.onclick +=
                    delegate
                {
                    foreach (var v in states)
                    {
                        if (v == state)
                        {
                            v.Selected = !v.Selected;

                            if (v.Selected)
                            {
                                v.Show();
                            }
                            else
                            {
                                v.Hide();
                            }
                        }
                        else
                        {
                            v.Selected = false;
                            v.Hide();
                        }
                    }
                };

                u.appendChild(btn, content);
            };


            SpawnCursor();


            u.AttachToDocument();

            Spawn(
                new global::SimpleRollover.HTML.Images.FromAssets.Untitled_1_03(),
                new global::SimpleRollover.HTML.Images.FromAssets.Untitled_2_03(),
                "This application was written in C#."
                );

            Spawn(
                new global::SimpleRollover.HTML.Images.FromAssets.Untitled_1_07(),
                new global::SimpleRollover.HTML.Images.FromAssets.Untitled_2_07(),

                "This application was cross compiled into JavaScript."
                );
        }
示例#44
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__Exception);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getMessage", "Message0", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getData", "Data1", "()Lsystem/collections/IDictionary;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetBaseException", "GetBaseException2", "()Lsystem/Exception;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getInnerException", "InnerException3", "()Lsystem/Exception;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getTargetSite", "TargetSite4", "()Lsystem/reflection/MethodBase;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getStackTraceNet", "StackTrace5", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getHelpLink", "HelpLink6", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setHelpLink", "HelpLink7", "(Ljava/lang/String;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getSource", "Source8", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setSource", "Source9", "(Ljava/lang/String;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ToString", "ToString10", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetObjectData", "GetObjectData11", "(Lsystem/runtime/serialization/SerializationInfo;Lsystem/runtime/serialization/St" +
                                                                   "reamingContext;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getHResult", "HResult12", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetType", "GetType13", "()Lsystem/Type;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Equals", "Equals14", "(Lsystem/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetHashCode", "GetHashCode15", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorException0", "__ctorException0", "(Lnet/sf/jni4net/inj/IClrProxy;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorException1", "__ctorException1", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorException2", "__ctorException2", "(Lnet/sf/jni4net/inj/IClrProxy;Ljava/lang/String;Lsystem/Exception;)V"));
     return(methods);
 }
示例#45
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__FieldInfo);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getFieldType", "FieldType0", "()Lsystem/Type;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetValue", "GetValue1", "(Lsystem/Object;)Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "SetValue", "SetValue2", "(Lsystem/Object;Lsystem/Object;Lsystem/reflection/BindingFlags;Lsystem/Object;Lsy" +
                                                                   "stem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getFieldHandle", "FieldHandle3", "()Lsystem/ValueType;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getAttributes", "Attributes4", "()Lsystem/Enum;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "SetValue", "SetValue5", "(Lsystem/Object;Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isPublic", "IsPublic6", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isPrivate", "IsPrivate7", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isFamily", "IsFamily8", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isAssembly", "IsAssembly9", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isFamilyAndAssembly", "IsFamilyAndAssembly10", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isFamilyOrAssembly", "IsFamilyOrAssembly11", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isStatic", "IsStatic12", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isInitOnly", "IsInitOnly13", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isLiteral", "IsLiteral14", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isNotSerialized", "IsNotSerialized15", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isSpecialName", "IsSpecialName16", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isPinvokeImpl", "IsPinvokeImpl17", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetFieldFromHandle", "GetFieldFromHandle18", "(Lsystem/ValueType;)Lsystem/reflection/FieldInfo;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetFieldFromHandle", "GetFieldFromHandle19", "(Lsystem/ValueType;Lsystem/ValueType;)Lsystem/reflection/FieldInfo;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetRequiredCustomModifiers", "GetRequiredCustomModifiers20", "()[Lsystem/Type;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetOptionalCustomModifiers", "GetOptionalCustomModifiers21", "()[Lsystem/Type;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetRawConstantValue", "GetRawConstantValue22", "()Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isSecurityCritical", "IsSecurityCritical23", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isSecuritySafeCritical", "IsSecuritySafeCritical24", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isSecurityTransparent", "IsSecurityTransparent25", "()Z"));
     return(methods);
 }
示例#46
0
        /// <summary>
        /// Returns a list of toolbox items for use with this DSL.
        /// </summary>
        public virtual global::System.Collections.Generic.IList <DslDesign::ModelingToolboxItem> CreateToolboxItems()
        {
            global::System.Collections.Generic.List <DslDesign::ModelingToolboxItem> toolboxItems = new global::System.Collections.Generic.List <DslDesign::ModelingToolboxItem>();

            // Create store and load domain models.
            using (DslModeling::Store store = new DslModeling::Store(this.ServiceProvider))
            {
                store.LoadDomainModels(typeof(DslDiagrams::CoreDesignSurfaceDomainModel),
                                       typeof(global::Altinoren.ActiveWriter.ActiveWriterDomainModel));
                global::System.Resources.ResourceManager resourceManager = global::Altinoren.ActiveWriter.ActiveWriterDomainModel.SingletonResourceManager;
                global::System.Globalization.CultureInfo resourceCulture = global::System.Globalization.CultureInfo.CurrentUICulture;

                // Open transaction so we can create model elements corresponding to toolbox items.
                using (DslModeling::Transaction t = store.TransactionManager.BeginTransaction("CreateToolboxItems"))
                {
                    // Add Class shape tool.
                    toolboxItems.Add(new DslDesign::ModelingToolboxItem(
                                         "ClassToolboxItem",                                                                                                                 // Unique identifier (non-localized) for the toolbox item.
                                         1,                                                                                                                                  // Position relative to other items in the same toolbox tab.
                                         resourceManager.GetString("ClassToolboxItem", resourceCulture),                                                                     // Localized display name for the item.
                                         (global::System.Drawing.Bitmap)DslDiagrams::ImageHelper.GetImage(resourceManager.GetObject("ClassToolboxBitmap", resourceCulture)), // Image displayed next to the toolbox item.
                                         "ActiveWriterToolboxTab",                                                                                                           // Unique identifier (non-localized) for the toolbox item tab.
                                         resourceManager.GetString("ActiveWriterToolboxTab", resourceCulture),                                                               // Localized display name for the toolbox tab.
                                         "CreateClassF1Keyword",                                                                                                             // F1 help keyword for the toolbox item.
                                         resourceManager.GetString("ClassToolboxTooltip", resourceCulture),                                                                  // Localized tooltip text for the toolbox item.
                                         CreateElementToolPrototype(store, global::Altinoren.ActiveWriter.ModelClass.DomainClassId),                                         // ElementGroupPrototype (data object) representing model element on the toolbox.
                                         new global::System.ComponentModel.ToolboxItemFilterAttribute[] {                                                                    // Collection of ToolboxItemFilterAttribute objects that determine visibility of the toolbox item.
                        new global::System.ComponentModel.ToolboxItemFilterAttribute(ToolboxFilterString, global::System.ComponentModel.ToolboxItemFilterType.Require)
                    }));

                    // Add ManyToOneRelationship connector tool.
                    toolboxItems.Add(new DslDesign::ModelingToolboxItem(
                                         "ManyToOneRelationshipToolboxItem",                                                                                                                 // Unique identifier (non-localized) for the toolbox item.
                                         2,                                                                                                                                                  // Position relative to other items in the same toolbox tab.
                                         resourceManager.GetString("ManyToOneRelationshipToolboxItem", resourceCulture),                                                                     // Localized display name for the item.
                                         (global::System.Drawing.Bitmap)DslDiagrams::ImageHelper.GetImage(resourceManager.GetObject("ManyToOneRelationshipToolboxBitmap", resourceCulture)), // Image displayed next to the toolbox item.
                                         "ActiveWriterToolboxTab",                                                                                                                           // Unique identifier (non-localized) for the toolbox item tab.
                                         resourceManager.GetString("ActiveWriterToolboxTab", resourceCulture),                                                                               // Localized display name for the toolbox tab.
                                         "ConnectRelationF1Keyword",                                                                                                                         // F1 help keyword for the toolbox item.
                                         resourceManager.GetString("ManyToOneRelationshipToolboxTooltip", resourceCulture),                                                                  // Localized tooltip text for the toolbox item.
                                         null,                                                                                                                                               // Connector toolbox items do not have an underlying data object.
                                         new global::System.ComponentModel.ToolboxItemFilterAttribute[] {                                                                                    // Collection of ToolboxItemFilterAttribute objects that determine visibility of the toolbox item.
                        new global::System.ComponentModel.ToolboxItemFilterAttribute(ToolboxFilterString, global::System.ComponentModel.ToolboxItemFilterType.Require),
                        new global::System.ComponentModel.ToolboxItemFilterAttribute(ManyToOneRelationshipFilterString)
                    }));

                    // Add ManyToManyRelationship connector tool.
                    toolboxItems.Add(new DslDesign::ModelingToolboxItem(
                                         "ManyToManyRelationshipToolboxItem",                                                                                                                 // Unique identifier (non-localized) for the toolbox item.
                                         3,                                                                                                                                                   // Position relative to other items in the same toolbox tab.
                                         resourceManager.GetString("ManyToManyRelationshipToolboxItem", resourceCulture),                                                                     // Localized display name for the item.
                                         (global::System.Drawing.Bitmap)DslDiagrams::ImageHelper.GetImage(resourceManager.GetObject("ManyToManyRelationshipToolboxBitmap", resourceCulture)), // Image displayed next to the toolbox item.
                                         "ActiveWriterToolboxTab",                                                                                                                            // Unique identifier (non-localized) for the toolbox item tab.
                                         resourceManager.GetString("ActiveWriterToolboxTab", resourceCulture),                                                                                // Localized display name for the toolbox tab.
                                         "ManyToManyRelationship",                                                                                                                            // F1 help keyword for the toolbox item.
                                         resourceManager.GetString("ManyToManyRelationshipToolboxTooltip", resourceCulture),                                                                  // Localized tooltip text for the toolbox item.
                                         null,                                                                                                                                                // Connector toolbox items do not have an underlying data object.
                                         new global::System.ComponentModel.ToolboxItemFilterAttribute[] {                                                                                     // Collection of ToolboxItemFilterAttribute objects that determine visibility of the toolbox item.
                        new global::System.ComponentModel.ToolboxItemFilterAttribute(ToolboxFilterString, global::System.ComponentModel.ToolboxItemFilterType.Require),
                        new global::System.ComponentModel.ToolboxItemFilterAttribute(ManyToManyRelationshipFilterString)
                    }));

                    // Add OneToOneRelationship connector tool.
                    toolboxItems.Add(new DslDesign::ModelingToolboxItem(
                                         "OneToOneRelationshipToolboxItem",                                                                                                                 // Unique identifier (non-localized) for the toolbox item.
                                         4,                                                                                                                                                 // Position relative to other items in the same toolbox tab.
                                         resourceManager.GetString("OneToOneRelationshipToolboxItem", resourceCulture),                                                                     // Localized display name for the item.
                                         (global::System.Drawing.Bitmap)DslDiagrams::ImageHelper.GetImage(resourceManager.GetObject("OneToOneRelationshipToolboxBitmap", resourceCulture)), // Image displayed next to the toolbox item.
                                         "ActiveWriterToolboxTab",                                                                                                                          // Unique identifier (non-localized) for the toolbox item tab.
                                         resourceManager.GetString("ActiveWriterToolboxTab", resourceCulture),                                                                              // Localized display name for the toolbox tab.
                                         "OneToOneRelationship",                                                                                                                            // F1 help keyword for the toolbox item.
                                         resourceManager.GetString("OneToOneRelationshipToolboxTooltip", resourceCulture),                                                                  // Localized tooltip text for the toolbox item.
                                         null,                                                                                                                                              // Connector toolbox items do not have an underlying data object.
                                         new global::System.ComponentModel.ToolboxItemFilterAttribute[] {                                                                                   // Collection of ToolboxItemFilterAttribute objects that determine visibility of the toolbox item.
                        new global::System.ComponentModel.ToolboxItemFilterAttribute(ToolboxFilterString, global::System.ComponentModel.ToolboxItemFilterType.Require),
                        new global::System.ComponentModel.ToolboxItemFilterAttribute(OneToOneRelationshipFilterString)
                    }));

                    // Add NestedClass shape tool.
                    toolboxItems.Add(new DslDesign::ModelingToolboxItem(
                                         "NestedClassToolboxItem",                                                                                                                 // Unique identifier (non-localized) for the toolbox item.
                                         5,                                                                                                                                        // Position relative to other items in the same toolbox tab.
                                         resourceManager.GetString("NestedClassToolboxItem", resourceCulture),                                                                     // Localized display name for the item.
                                         (global::System.Drawing.Bitmap)DslDiagrams::ImageHelper.GetImage(resourceManager.GetObject("NestedClassToolboxBitmap", resourceCulture)), // Image displayed next to the toolbox item.
                                         "ActiveWriterToolboxTab",                                                                                                                 // Unique identifier (non-localized) for the toolbox item tab.
                                         resourceManager.GetString("ActiveWriterToolboxTab", resourceCulture),                                                                     // Localized display name for the toolbox tab.
                                         "NestedClassF1Keyword",                                                                                                                   // F1 help keyword for the toolbox item.
                                         resourceManager.GetString("NestedClassToolboxTooltip", resourceCulture),                                                                  // Localized tooltip text for the toolbox item.
                                         CreateElementToolPrototype(store, global::Altinoren.ActiveWriter.NestedClass.DomainClassId),                                              // ElementGroupPrototype (data object) representing model element on the toolbox.
                                         new global::System.ComponentModel.ToolboxItemFilterAttribute[] {                                                                          // Collection of ToolboxItemFilterAttribute objects that determine visibility of the toolbox item.
                        new global::System.ComponentModel.ToolboxItemFilterAttribute(ToolboxFilterString, global::System.ComponentModel.ToolboxItemFilterType.Require)
                    }));

                    // Add NestedRelationship connector tool.
                    toolboxItems.Add(new DslDesign::ModelingToolboxItem(
                                         "NestedRelationshipToolboxItem",                                                                                                                 // Unique identifier (non-localized) for the toolbox item.
                                         6,                                                                                                                                               // Position relative to other items in the same toolbox tab.
                                         resourceManager.GetString("NestedRelationshipToolboxItem", resourceCulture),                                                                     // Localized display name for the item.
                                         (global::System.Drawing.Bitmap)DslDiagrams::ImageHelper.GetImage(resourceManager.GetObject("NestedRelationshipToolboxBitmap", resourceCulture)), // Image displayed next to the toolbox item.
                                         "ActiveWriterToolboxTab",                                                                                                                        // Unique identifier (non-localized) for the toolbox item tab.
                                         resourceManager.GetString("ActiveWriterToolboxTab", resourceCulture),                                                                            // Localized display name for the toolbox tab.
                                         "NestedRelationship",                                                                                                                            // F1 help keyword for the toolbox item.
                                         resourceManager.GetString("NestedRelationshipToolboxTooltip", resourceCulture),                                                                  // Localized tooltip text for the toolbox item.
                                         null,                                                                                                                                            // Connector toolbox items do not have an underlying data object.
                                         new global::System.ComponentModel.ToolboxItemFilterAttribute[] {                                                                                 // Collection of ToolboxItemFilterAttribute objects that determine visibility of the toolbox item.
                        new global::System.ComponentModel.ToolboxItemFilterAttribute(ToolboxFilterString, global::System.ComponentModel.ToolboxItemFilterType.Require),
                        new global::System.ComponentModel.ToolboxItemFilterAttribute(NestedRelationshipFilterString)
                    }));

                    t.Rollback();
                }
            }

            return(toolboxItems);
        }
示例#47
0
        public @MultiSelectApplicationsUIModel() : base()
        {
            _donation              = new global::Blackbaud.AppFx.UIModeling.Core.BooleanField();
            _eventregistration     = new global::Blackbaud.AppFx.UIModeling.Core.BooleanField();
            _matchinggift          = new global::Blackbaud.AppFx.UIModeling.Core.BooleanField();
            _plannedgift           = new global::Blackbaud.AppFx.UIModeling.Core.BooleanField();
            _pledge                = new global::Blackbaud.AppFx.UIModeling.Core.BooleanField();
            _recurringgift         = new global::Blackbaud.AppFx.UIModeling.Core.BooleanField();
            _other                 = new global::Blackbaud.AppFx.UIModeling.Core.BooleanField();
            _applicationsdelimited = new global::Blackbaud.AppFx.UIModeling.Core.StringField();
            _selectall             = new global::Blackbaud.AppFx.UIModeling.Core.GenericUIAction();
            _unselect              = new global::Blackbaud.AppFx.UIModeling.Core.GenericUIAction();
            _applications          = new global::System.Collections.Generic.List <BooleanField>();

            this.FORMHEADER.Value = "Select applications";
            this.UserInterfaceUrl = "browser/htmlforms/custom/reportingmultiselect/MultiSelectApplications.html";

            //
            //_donation
            //
            _donation.Name    = "DONATION";
            _donation.Caption = "Donation";
            this.Fields.Add(_donation);
            //
            //_eventregistration
            //
            _eventregistration.Name    = "EVENTREGISTRATION";
            _eventregistration.Caption = "Event registration";
            this.Fields.Add(_eventregistration);
            //
            //_matchinggift
            //
            _matchinggift.Name    = "MATCHINGGIFT";
            _matchinggift.Caption = "Matching gift";
            this.Fields.Add(_matchinggift);
            //
            //_plannedgift
            //
            _plannedgift.Name    = "PLANNEDGIFT";
            _plannedgift.Caption = "Planned gift";
            this.Fields.Add(_plannedgift);
            //
            //_pledge
            //
            _pledge.Name    = "PLEDGE";
            _pledge.Caption = "Pledge";
            this.Fields.Add(_pledge);
            //
            //_recurringgift
            //
            _recurringgift.Name    = "RECURRINGGIFT";
            _recurringgift.Caption = "Recurring gift";
            this.Fields.Add(_recurringgift);
            //
            //_other
            //
            _other.Name    = "OTHER";
            _other.Caption = "Other";
            this.Fields.Add(_other);
            //
            //_applicationsdelimited
            //
            _applicationsdelimited.Name    = "APPLICATIONSDELIMITED";
            _applicationsdelimited.Caption = "APPLICATIONSDELIMITED";
            this.Fields.Add(_applicationsdelimited);
            //
            //_selectall
            //
            _selectall.Name    = "SELECTALL";
            _selectall.Caption = "Select all";
            this.Actions.Add(_selectall);
            //
            //_unselect
            //
            _unselect.Name    = "UNSELECT";
            _unselect.Caption = "Unselect all";
            this.Actions.Add(_unselect);

            _applications.Add(_donation);
            _applications.Add(_eventregistration);
            _applications.Add(_matchinggift);
            _applications.Add(_plannedgift);
            _applications.Add(_pledge);
            _applications.Add(_recurringgift);
            _applications.Add(_other);

            OnCreated();
        }
示例#48
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__IScoreSnapshot);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "compareTo", "compareTo0", "(Ljava/lang/Object;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getName", "getName1", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getTotalScore", "getTotalScore2", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getTotalSurvivalScore", "getTotalSurvivalScore3", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getTotalLastSurvivorBonus", "getTotalLastSurvivorBonus4", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getTotalBulletDamageScore", "getTotalBulletDamageScore5", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getTotalBulletKillBonus", "getTotalBulletKillBonus6", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getTotalRammingDamageScore", "getTotalRammingDamageScore7", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getTotalRammingKillBonus", "getTotalRammingKillBonus8", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getTotalFirsts", "getTotalFirsts9", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getTotalSeconds", "getTotalSeconds10", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getTotalThirds", "getTotalThirds11", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCurrentScore", "getCurrentScore12", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCurrentSurvivalScore", "getCurrentSurvivalScore13", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCurrentSurvivalBonus", "getCurrentSurvivalBonus14", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCurrentBulletDamageScore", "getCurrentBulletDamageScore15", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCurrentBulletKillBonus", "getCurrentBulletKillBonus16", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCurrentRammingDamageScore", "getCurrentRammingDamageScore17", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCurrentRammingKillBonus", "getCurrentRammingKillBonus18", "()D"));
     return(methods);
 }
示例#49
0
 // Token: 0x060002A6 RID: 678 RVA: 0x00010218 File Offset: 0x0000E418
 protected override global::System.Collections.Generic.IEnumerable <global::VRGIN.Controls.IShortcut> CreateShortcuts()
 {
     global::System.Collections.Generic.List <global::VRGIN.Controls.IShortcut> list = new global::System.Collections.Generic.List <global::VRGIN.Controls.IShortcut>();
     list.Add(new global::VRGIN.Controls.KeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.GUIRaise, this.MoveGUI(0.1f)));
     list.Add(new global::VRGIN.Controls.KeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.GUILower, this.MoveGUI(-0.1f)));
     list.Add(new global::VRGIN.Controls.KeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.GUIIncreaseAngle, delegate()
     {
         global::VRGIN.Core.VR.Settings.Angle += global::UnityEngine.Time.deltaTime * 50f;
     }));
     list.Add(new global::VRGIN.Controls.KeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.GUIDecreaseAngle, delegate()
     {
         global::VRGIN.Core.VR.Settings.Angle -= global::UnityEngine.Time.deltaTime * 50f;
     }));
     list.Add(new global::VRGIN.Controls.KeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.GUIIncreaseDistance, delegate()
     {
         global::VRGIN.Core.VR.Settings.Distance += global::UnityEngine.Time.deltaTime * 0.1f;
     }));
     list.Add(new global::VRGIN.Controls.KeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.GUIDecreaseDistance, delegate()
     {
         global::VRGIN.Core.VR.Settings.Distance -= global::UnityEngine.Time.deltaTime * 0.1f;
     }));
     list.Add(new global::VRGIN.Controls.KeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.GUIRotateLeft, delegate()
     {
         global::VRGIN.Core.VR.Settings.Rotation += global::UnityEngine.Time.deltaTime * 50f;
     }));
     list.Add(new global::VRGIN.Controls.KeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.GUIRotateRight, delegate()
     {
         global::VRGIN.Core.VR.Settings.Rotation -= global::UnityEngine.Time.deltaTime * 50f;
     }));
     list.Add(new global::VRGIN.Controls.KeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.GUIChangeProjection, new global::System.Action(this.ChangeProjection)));
     list.Add(new global::VRGIN.Controls.MultiKeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.ToggleRotationLock, new global::System.Action(this.ToggleRotationLock)));
     list.Add(new global::VRGIN.Controls.MultiKeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.ImpersonateApproximately, delegate()
     {
         bool flag = this.LockTarget == null || !this.LockTarget.IsValid;
         if (flag)
         {
             this.Impersonate(global::VRGIN.Core.VR.Interpreter.FindNextActorToImpersonate(), global::VRGIN.Modes.ImpersonationMode.Approximately);
         }
         else
         {
             this.Impersonate(null);
         }
     }));
     list.Add(new global::VRGIN.Controls.MultiKeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.ImpersonateExactly, delegate()
     {
         bool flag = this.LockTarget == null || !this.LockTarget.IsValid;
         if (flag)
         {
             this.Impersonate(global::VRGIN.Core.VR.Interpreter.FindNextActorToImpersonate(), global::VRGIN.Modes.ImpersonationMode.Exactly);
         }
         else
         {
             this.Impersonate(null);
         }
     }));
     list.Add(new global::VRGIN.Controls.MultiKeyboardShortcut(global::VRGIN.Core.VR.Shortcuts.ResetView, new global::System.Action(this.Recenter)));
     return(global::System.Linq.Enumerable.Concat <global::VRGIN.Controls.IShortcut>(list, base.CreateShortcuts()));
 }
示例#50
0
        protected override void GeneratePostInitializationCode(string directiveName, global::System.Text.StringBuilder codeBuffer, global::System.CodeDom.Compiler.CodeDomProvider languageProvider, global::System.Collections.Generic.IDictionary <string, string> requiresArguments, global::System.Collections.Generic.IDictionary <string, string> providesArguments)
        {
            if ((global::System.StringComparer.OrdinalIgnoreCase.Compare(directiveName, supportedDirectiveName) == 0))
            {
                // We check the encoding of the model file, and ask the host to use that
                // encoding to write the output. This is to make sure we use the correct encoding
                // if the model file contains international characters that could be used in
                // the template output.
                string fileName = requiresArguments[requiresFileParameter];
                if (!string.IsNullOrEmpty(fileName) && global::System.IO.File.Exists(fileName))
                {
                    Host.SetOutputEncoding(VSTextTemplating::EncodingHelper.GetEncoding(fileName), false);
                }

                if (languageProvider != null)
                {
                    global::System.CodeDom.CodeMethodInvokeExpression invokeLoad;
                    global::System.String transactionName = providesArguments[providesModelParameter].ToLower(global::System.Globalization.CultureInfo.InvariantCulture) + "Transaction";
                    global::System.CodeDom.CodeVariableDeclarationStatement transactionDeclaration = new global::System.CodeDom.CodeVariableDeclarationStatement(new global::System.CodeDom.CodeTypeReference(typeof(DslModeling::Transaction)), transactionName, new global::System.CodeDom.CodePrimitiveExpression(null));
                    global::System.CodeDom.CodeStatement finallyStatement = new global::System.CodeDom.CodeConditionStatement(new global::System.CodeDom.CodeBinaryOperatorExpression(new global::System.CodeDom.CodeVariableReferenceExpression(transactionName), global::System.CodeDom.CodeBinaryOperatorType.IdentityInequality, new global::System.CodeDom.CodePrimitiveExpression(null)), new global::System.CodeDom.CodeExpressionStatement(new global::System.CodeDom.CodeMethodInvokeExpression(new global::System.CodeDom.CodeVariableReferenceExpression(transactionName), "Dispose")));
                    global::System.Collections.Generic.List <global::System.CodeDom.CodeStatement> txTryStatements = new global::System.Collections.Generic.List <global::System.CodeDom.CodeStatement>();
                    global::System.CodeDom.CodeVariableDeclarationStatement serializationResultDeclaration         = new global::System.CodeDom.CodeVariableDeclarationStatement(new global::System.CodeDom.CodeTypeReference(typeof(DslModeling::SerializationResult)), "serializationResult", new global::System.CodeDom.CodeObjectCreateExpression(new global::System.CodeDom.CodeTypeReference(typeof(DslModeling::SerializationResult))));

                    global::System.CodeDom.CodeMethodInvokeExpression       invokeEnableDiagramRules = null;
                    global::System.CodeDom.CodeVariableDeclarationStatement diagramFileDeclaration   = null;
                    global::System.CodeDom.CodeAssignStatement diagramFileAssign = null;
                    if (LoadDiagramData)
                    {
                        // generate code to enable diagram fixup rules and load the diagram if required.
                        invokeEnableDiagramRules = new global::System.CodeDom.CodeMethodInvokeExpression(
                            new global::System.CodeDom.CodeMethodReferenceExpression(new global::System.CodeDom.CodeTypeReferenceExpression("SequencerDomainModel"), "EnableDiagramRules"), new global::System.CodeDom.CodePropertyReferenceExpression(new global::System.CodeDom.CodeThisReferenceExpression(), "Store"));
                        diagramFileDeclaration = new global::System.CodeDom.CodeVariableDeclarationStatement(new global::System.CodeDom.CodeTypeReference("System.String"), "diagramFileName");
                        diagramFileAssign      = new global::System.CodeDom.CodeAssignStatement(new global::System.CodeDom.CodeVariableReferenceExpression("diagramFileName"), new global::System.CodeDom.CodeBinaryOperatorExpression(new global::System.CodeDom.CodePrimitiveExpression(requiresArguments[requiresFileParameter]), global::System.CodeDom.CodeBinaryOperatorType.Add, new global::System.CodeDom.CodePrimitiveExpression(".diagram")));
                        invokeLoad             = new global::System.CodeDom.CodeMethodInvokeExpression(
                            new global::System.CodeDom.CodeMethodReferenceExpression(new global::System.CodeDom.CodeFieldReferenceExpression(new global::System.CodeDom.CodeTypeReferenceExpression(typeof(SequencerSerializationHelper)), "Instance"), "LoadModelAndDiagram"), new global::System.CodeDom.CodeVariableReferenceExpression("serializationResult"), new global::System.CodeDom.CodePropertyReferenceExpression(new global::System.CodeDom.CodeThisReferenceExpression(), "Store"), new global::System.CodeDom.CodePrimitiveExpression(requiresArguments[requiresFileParameter]), new global::System.CodeDom.CodeVariableReferenceExpression("diagramFileName"), new global::System.CodeDom.CodePrimitiveExpression(null), new global::System.CodeDom.CodePrimitiveExpression(null), new global::System.CodeDom.CodePrimitiveExpression(null));
                    }
                    else
                    {
                        invokeLoad = new global::System.CodeDom.CodeMethodInvokeExpression(
                            new global::System.CodeDom.CodeMethodReferenceExpression(new global::System.CodeDom.CodeFieldReferenceExpression(new global::System.CodeDom.CodeTypeReferenceExpression(typeof(SequencerSerializationHelper)), "Instance"), "LoadModel"), new global::System.CodeDom.CodeVariableReferenceExpression("serializationResult"), new global::System.CodeDom.CodePropertyReferenceExpression(new global::System.CodeDom.CodeThisReferenceExpression(), "Store"), new global::System.CodeDom.CodePrimitiveExpression(requiresArguments[requiresFileParameter]), new global::System.CodeDom.CodePrimitiveExpression(null), new global::System.CodeDom.CodePrimitiveExpression(null), new global::System.CodeDom.CodePrimitiveExpression(null));
                    }

                    global::System.CodeDom.CodeAssignStatement loadAssign = new global::System.CodeDom.CodeAssignStatement(new global::System.CodeDom.CodeFieldReferenceExpression(new global::System.CodeDom.CodeThisReferenceExpression(), providesArguments[providesModelParameter].ToLower(global::System.Globalization.CultureInfo.InvariantCulture) + "Value"), invokeLoad);
                    txTryStatements.Add(serializationResultDeclaration);
                    txTryStatements.Add(new global::System.CodeDom.CodeAssignStatement(new global::System.CodeDom.CodeVariableReferenceExpression(transactionName), new global::System.CodeDom.CodeMethodInvokeExpression(new global::System.CodeDom.CodePropertyReferenceExpression(new global::System.CodeDom.CodePropertyReferenceExpression(new global::System.CodeDom.CodeThisReferenceExpression(), "Store"), "TransactionManager"), "BeginTransaction", new global::System.CodeDom.CodePrimitiveExpression("Load"), new global::System.CodeDom.CodePrimitiveExpression(true))));
                    txTryStatements.Add(loadAssign);
                    global::System.CodeDom.CodeConditionStatement serializationResultCheck = new global::System.CodeDom.CodeConditionStatement(
                        new global::System.CodeDom.CodePropertyReferenceExpression(new global::System.CodeDom.CodeVariableReferenceExpression("serializationResult"), "Failed"),
                        new global::System.CodeDom.CodeThrowExceptionStatement(new global::System.CodeDom.CodeObjectCreateExpression(new global::System.CodeDom.CodeTypeReference(typeof(DslModeling::SerializationException)), new global::System.CodeDom.CodeVariableReferenceExpression("serializationResult")))
                        );
                    txTryStatements.Add(serializationResultCheck);
                    txTryStatements.Add(new global::System.CodeDom.CodeExpressionStatement(new global::System.CodeDom.CodeMethodInvokeExpression(new global::System.CodeDom.CodeVariableReferenceExpression(transactionName), "Commit")));
                    global::System.CodeDom.CodeTryCatchFinallyStatement txTryStatement = new global::System.CodeDom.CodeTryCatchFinallyStatement(txTryStatements.ToArray(), new global::System.CodeDom.CodeCatchClause[] { }, new global::System.CodeDom.CodeStatement[] { finallyStatement });


                    // We check if the user has requested validation to be performed. If so, we call
                    // ValidateStore() on the base ModelingTextTransformation class.
                    string validationCategories = requiresArguments[requiresValidationParameter];
                    global::System.CodeDom.CodeMethodInvokeExpression validationInvoke = null;
                    if (!string.IsNullOrEmpty(validationCategories))
                    {
                        validationInvoke = new global::System.CodeDom.CodeMethodInvokeExpression(new global::System.CodeDom.CodeThisReferenceExpression(), "ValidateStore", new global::System.CodeDom.CodePrimitiveExpression(validationCategories), new global::System.CodeDom.CodePropertyReferenceExpression(new global::System.CodeDom.CodeThisReferenceExpression(), "Errors"));
                    }

                    global::System.CodeDom.Compiler.CodeGeneratorOptions options = new global::System.CodeDom.Compiler.CodeGeneratorOptions();
                    options.BlankLinesBetweenMembers = true;
                    options.IndentString             = "    ";
                    options.VerbatimOrder            = true;
                    options.BracingStyle             = "C";
                    using (global::System.IO.StringWriter writer = new global::System.IO.StringWriter(codeBuffer, global::System.Globalization.CultureInfo.InvariantCulture))
                    {
                        if (invokeEnableDiagramRules != null)
                        {
                            languageProvider.GenerateCodeFromStatement(new global::System.CodeDom.CodeExpressionStatement(invokeEnableDiagramRules), writer, options);
                        }

                        if (diagramFileDeclaration != null)
                        {
                            languageProvider.GenerateCodeFromStatement(diagramFileDeclaration, writer, options);
                            languageProvider.GenerateCodeFromStatement(diagramFileAssign, writer, options);
                        }

                        languageProvider.GenerateCodeFromStatement(transactionDeclaration, writer, options);
                        languageProvider.GenerateCodeFromStatement(txTryStatement, writer, options);

                        if (validationInvoke != null)
                        {
                            languageProvider.GenerateCodeFromStatement(new global::System.CodeDom.CodeExpressionStatement(validationInvoke), writer, options);
                        }
                    }
                }
            }
        }
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__Hashtable);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetEnumerator", "GetEnumerator0", "()Lsystem/collections/IDictionaryEnumerator;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "CopyTo", "CopyTo1", "(Lsystem/Array;I)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCount", "Count2", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getSyncRoot", "SyncRoot3", "()Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isSynchronized", "IsSynchronized4", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getItem", "Item5", "(Lsystem/Object;)Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setItem", "Item6", "(Lsystem/Object;Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getKeys", "Keys7", "()Lsystem/collections/ICollection;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getValues", "Values8", "()Lsystem/collections/ICollection;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Contains", "Contains9", "(Lsystem/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Add", "Add10", "(Lsystem/Object;Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Clear", "Clear11", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isReadOnly", "IsReadOnly12", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isFixedSize", "IsFixedSize13", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Remove", "Remove14", "(Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetObjectData", "GetObjectData15", "(Lsystem/runtime/serialization/SerializationInfo;Lsystem/runtime/serialization/St" +
                                                                   "reamingContext;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "OnDeserialization", "OnDeserialization16", "(Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Clone", "Clone17", "()Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ContainsKey", "ContainsKey18", "(Lsystem/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ContainsValue", "ContainsValue19", "(Lsystem/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Synchronized", "Synchronized20", "(Lsystem/collections/Hashtable;)Lsystem/collections/Hashtable;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable0", "__ctorHashtable0", "(Lnet/sf/jni4net/inj/IClrProxy;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable1", "__ctorHashtable1", "(Lnet/sf/jni4net/inj/IClrProxy;I)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable2", "__ctorHashtable2", "(Lnet/sf/jni4net/inj/IClrProxy;IF)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable3", "__ctorHashtable3", "(Lnet/sf/jni4net/inj/IClrProxy;IFLsystem/Object;Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable4", "__ctorHashtable4", "(Lnet/sf/jni4net/inj/IClrProxy;IFLsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable5", "__ctorHashtable5", "(Lnet/sf/jni4net/inj/IClrProxy;Lsystem/Object;Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable6", "__ctorHashtable6", "(Lnet/sf/jni4net/inj/IClrProxy;Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable7", "__ctorHashtable7", "(Lnet/sf/jni4net/inj/IClrProxy;ILsystem/Object;Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable8", "__ctorHashtable8", "(Lnet/sf/jni4net/inj/IClrProxy;ILsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable9", "__ctorHashtable9", "(Lnet/sf/jni4net/inj/IClrProxy;Lsystem/collections/IDictionary;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable10", "__ctorHashtable10", "(Lnet/sf/jni4net/inj/IClrProxy;Lsystem/collections/IDictionary;F)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable11", "__ctorHashtable11", "(Lnet/sf/jni4net/inj/IClrProxy;Lsystem/collections/IDictionary;Lsystem/Object;Lsy" +
                                                                   "stem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable12", "__ctorHashtable12", "(Lnet/sf/jni4net/inj/IClrProxy;Lsystem/collections/IDictionary;Lsystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable13", "__ctorHashtable13", "(Lnet/sf/jni4net/inj/IClrProxy;Lsystem/collections/IDictionary;FLsystem/Object;Ls" +
                                                                   "ystem/Object;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorHashtable14", "__ctorHashtable14", "(Lnet/sf/jni4net/inj/IClrProxy;Lsystem/collections/IDictionary;FLsystem/Object;)V" +
                                                                   ""));
     return(methods);
 }
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__IBattleListener);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "onBattleStarted", "onBattleStarted0", "(Lrobocode/control/events/BattleStartedEvent;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "onBattleFinished", "onBattleFinished1", "(Lrobocode/control/events/BattleFinishedEvent;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "onBattleCompleted", "onBattleCompleted2", "(Lrobocode/control/events/BattleCompletedEvent;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "onBattlePaused", "onBattlePaused3", "(Lrobocode/control/events/BattlePausedEvent;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "onBattleResumed", "onBattleResumed4", "(Lrobocode/control/events/BattleResumedEvent;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "onRoundStarted", "onRoundStarted5", "(Lrobocode/control/events/RoundStartedEvent;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "onRoundEnded", "onRoundEnded6", "(Lrobocode/control/events/RoundEndedEvent;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "onTurnStarted", "onTurnStarted7", "(Lrobocode/control/events/TurnStartedEvent;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "onTurnEnded", "onTurnEnded8", "(Lrobocode/control/events/TurnEndedEvent;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "onBattleMessage", "onBattleMessage9", "(Lrobocode/control/events/BattleMessageEvent;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "onBattleError", "onBattleError10", "(Lrobocode/control/events/BattleErrorEvent;)V"));
     return(methods);
 }
示例#53
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__Scanner);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Setup", "Setup0", "()Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "SetEventListener", "SetEventListener1", "(Llogitowwindowsnative/DeviceEventReceiver;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetConnectedLogitowDevice", "GetConnectedLogitowDevice2", "(Ljava/lang/String;)Llogitowwindowsnative/LogitowDevice;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetDiscoveredLogitowDevice", "GetDiscoveredLogitowDevice3", "(Ljava/lang/String;)Llogitowwindowsnative/LogitowDevice;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetBluetoothSupported", "GetBluetoothSupported4", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetBluetoothEnabled", "GetBluetoothEnabled5", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "StartBleDeviceWatcher", "StartBleDeviceWatcher6", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "StopBleDeviceWatcher", "StopBleDeviceWatcher7", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Connect", "Connect8", "(Llogitowwindowsnative/LogitowDevice;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Disconnect", "Disconnect9", "(Llogitowwindowsnative/LogitowDevice;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorScanner0", "__ctorScanner0", "(Lnet/sf/jni4net/inj/IClrProxy;)V"));
     return(methods);
 }
示例#54
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__Stream);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Dispose", "Dispose0", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCanRead", "CanRead1", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCanSeek", "CanSeek2", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCanTimeout", "CanTimeout3", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getCanWrite", "CanWrite4", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getLength", "Length5", "()J"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getPosition", "Position6", "()J"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setPosition", "Position7", "(J)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getReadTimeout", "ReadTimeout8", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setReadTimeout", "ReadTimeout9", "(I)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getWriteTimeout", "WriteTimeout10", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "setWriteTimeout", "WriteTimeout11", "(I)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Close", "Close12", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Flush", "Flush13", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "BeginRead", "BeginRead14", "([BIILsystem/AsyncCallback;Lsystem/Object;)Lsystem/IAsyncResult;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "EndRead", "EndRead15", "(Lsystem/IAsyncResult;)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "BeginWrite", "BeginWrite16", "([BIILsystem/AsyncCallback;Lsystem/Object;)Lsystem/IAsyncResult;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "EndWrite", "EndWrite17", "(Lsystem/IAsyncResult;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Seek", "Seek18", "(JLsystem/Enum;)J"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "SetLength", "SetLength19", "(J)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Read", "Read20", "([BII)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ReadByte", "ReadByte21", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Write", "Write22", "([BII)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "WriteByte", "WriteByte23", "(B)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Synchronized", "Synchronized24", "(Lsystem/io/Stream;)Lsystem/io/Stream;"));
     return(methods);
 }
    public partial global::System.Collections.Generic.List <global::SomeType> List(global::System.Data.Common.DbConnection connection, int id, string name)
    {
        // locals
        global::System.Data.Common.DbCommand?   __dapper__command = null;
        global::System.Data.Common.DbDataReader?__dapper__reader  = null;
        bool __dapper__close = false;

        int[]? __dapper__tokenBuffer = null;
        global::System.Collections.Generic.List <global::SomeType> __dapper__result;
        try
        {
            // prepare connection
            if (connection !.State == global::System.Data.ConnectionState.Closed)
            {
                connection !.Open();
                __dapper__close = true;
            }

            // prepare command (excluding parameter values)
            if ((__dapper__command = global::System.Threading.Interlocked.Exchange(ref s___dapper__command_Samples_Sync_Multiple_input_cs_List_8, null)) is null)
            {
                __dapper__command = __dapper__CreateCommand(connection !);
            }
            else
            {
                __dapper__command.Connection = connection;
            }

            // assign parameter values
#pragma warning disable CS0618
            __dapper__command.Parameters[0].Value = global::Dapper.Internal.InternalUtilities.AsValue(id);
            __dapper__command.Parameters[1].Value = global::Dapper.Internal.InternalUtilities.AsValue(name);
#pragma warning restore CS0618

            // execute reader
            const global::System.Data.CommandBehavior __dapper__behavior = global::System.Data.CommandBehavior.SequentialAccess | global::System.Data.CommandBehavior.SingleResult | global::System.Data.CommandBehavior.SingleRow;
            __dapper__reader = __dapper__command.ExecuteReader(__dapper__close ? (__dapper__behavior | global::System.Data.CommandBehavior.CloseConnection) : __dapper__behavior);
            __dapper__close  = false;            // performed via CommandBehavior

            // process multiple rows
            __dapper__result = new global::System.Collections.Generic.List <global::SomeType>();
            if (__dapper__reader.HasRows)
            {
                var __dapper__parser = global::Dapper.TypeReader.TryGetReader <global::SomeType>() !;
                global::System.Span <int> __dapper__tokens = __dapper__reader.FieldCount <= global::Dapper.TypeReader.MaxStackTokens ? stackalloc int[__dapper__reader.FieldCount] : global::Dapper.TypeReader.RentSpan(ref __dapper__tokenBuffer, __dapper__reader.FieldCount);
                __dapper__parser.IdentifyFieldTokensFromSchema(__dapper__reader, __dapper__tokens);
                while (__dapper__reader.Read())
                {
                    __dapper__result.Add(__dapper__parser.Read(__dapper__reader, __dapper__tokens));
                }
            }
            // consume additional results (ensures errors from the server are observed)
            while (__dapper__reader.NextResult())
            {
            }

            // TODO: post-process parameters

            // return rowset
            return(__dapper__result);
        }
        finally
        {
            // cleanup
            global::Dapper.TypeReader.Return(ref __dapper__tokenBuffer);
            __dapper__reader?.Dispose();
            if (__dapper__command is not null)
            {
                __dapper__command.Connection = default;
                __dapper__command            = global::System.Threading.Interlocked.Exchange(ref s___dapper__command_Samples_Sync_Multiple_input_cs_List_8, __dapper__command);
                __dapper__command?.Dispose();
            }
            if (__dapper__close)
            {
                connection?.Close();
            }
        }
示例#56
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__Set);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "iterator", "iterator0", "()Ljava/util/Iterator;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "hashCode", "hashCode1", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "add", "add2", "(Ljava/lang/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "clear", "clear3", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "equals", "equals4", "(Ljava/lang/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "contains", "contains5", "(Ljava/lang/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "addAll", "addAll6", "(Ljava/util/Collection;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "size", "size7", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "toArray", "toArray8", "([Ljava/lang/Object;)[Ljava/lang/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "toArray", "toArray9", "()[Ljava/lang/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "remove", "remove10", "(Ljava/lang/Object;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isEmpty", "isEmpty11", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "containsAll", "containsAll12", "(Ljava/util/Collection;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "removeAll", "removeAll13", "(Ljava/util/Collection;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "retainAll", "retainAll14", "(Ljava/util/Collection;)Z"));
     return(methods);
 }
示例#57
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__Win10BLE);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ConnectBLE", "ConnectBLE0", "(Ljava/lang/String;)Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "DisconnectBLE", "DisconnectBLE1", "()V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "DiscoverUEI", "DiscoverUEI2", "(Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ConnectUEI", "ConnectUEI3", "(Ljava/lang/String;)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "DisconnectUEI", "DisconnectUEI4", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "DiscoverServices", "DiscoverServices5", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetFeatures", "GetFeatures6", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetSubscription", "GetSubscription7", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetStage", "GetStage8", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "SetDisconnecting", "SetDisconnecting9", "(Z)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "IsDisconnecting", "IsDisconnecting10", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "IsScanning", "IsScanning11", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "IsConnected", "IsConnected12", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "HasCCCD", "HasCCCD13", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "NeedsCCCD", "NeedsCCCD14", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetListSize", "GetListSize15", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetListItem", "GetListItem16", "(I)Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetItemName", "GetItemName17", "(I)Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetRssi", "GetRssi18", "(I)I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetInCount", "GetInCount19", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetInDataSize", "GetInDataSize20", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetInData", "GetInData21", "(I)[B"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "ReadSignalStrength", "ReadSignalStrength22", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "WritePacket", "WritePacket23", "([B)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetSentState", "GetSentState24", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "SetSentState", "SetSentState25", "(I)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "UpdateConnection", "UpdateConnection26", "(IIII)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetBLEStack", "GetBLEStack27", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "__ctorWin10BLE0", "__ctorWin10BLE0", "(Lnet/sf/jni4net/inj/IClrProxy;)V"));
     return(methods);
 }
示例#58
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__ParameterInfo);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetCustomAttributes", "GetCustomAttributes0", "(Z)[Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetCustomAttributes", "GetCustomAttributes1", "(Lsystem/Type;Z)[Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "IsDefined", "IsDefined2", "(Lsystem/Type;Z)Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetTypeInfoCount", "GetTypeInfoCount3", "(Lnet/sf/jni4net/Out;)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetTypeInfo", "GetTypeInfo4", "(IIJ)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetIDsOfNames", "GetIDsOfNames5", "(Lnet/sf/jni4net/Ref;JIIJ)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "Invoke", "Invoke6", "(ILnet/sf/jni4net/Ref;ISJJJJ)V"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getParameterType", "ParameterType7", "()Lsystem/Type;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getName", "Name8", "()Ljava/lang/String;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getDefaultValue", "DefaultValue9", "()Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getRawDefaultValue", "RawDefaultValue10", "()Lsystem/Object;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getPosition", "Position11", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getAttributes", "Attributes12", "()Lsystem/Enum;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getMember", "Member13", "()Lsystem/reflection/MemberInfo;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isIn", "IsIn14", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isOut", "IsOut15", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isLcid", "IsLcid16", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isRetval", "IsRetval17", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isOptional", "IsOptional18", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getMetadataToken", "MetadataToken19", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetRequiredCustomModifiers", "GetRequiredCustomModifiers20", "()[Lsystem/Type;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "GetOptionalCustomModifiers", "GetOptionalCustomModifiers21", "()[Lsystem/Type;"));
     return(methods);
 }
示例#59
0
 private static global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> @__Init(global::net.sf.jni4net.jni.JNIEnv @__env, global::java.lang.Class @__class)
 {
     global::System.Type @__type = typeof(__IBulletSnapshot);
     global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod> methods = new global::System.Collections.Generic.List <global::net.sf.jni4net.jni.JNINativeMethod>();
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getState", "getState0", "()Lrobocode/control/snapshot/BulletState;"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getPower", "getPower1", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getX", "getX2", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getY", "getY3", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getPaintX", "getPaintX4", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getPaintY", "getPaintY5", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getColor", "getColor6", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getFrame", "getFrame7", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "isExplosion", "isExplosion8", "()Z"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getExplosionImageIndex", "getExplosionImageIndex9", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getBulletId", "getBulletId10", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getHeading", "getHeading11", "()D"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getVictimIndex", "getVictimIndex12", "()I"));
     methods.Add(global::net.sf.jni4net.jni.JNINativeMethod.Create(@__type, "getOwnerIndex", "getOwnerIndex13", "()I"));
     return(methods);
 }
示例#60
0
        public object Read3_ArrayOfPersistModel(string defaultNamespace = null)
        {
            object o = null;

            Reader.MoveToContent();
            if (Reader.NodeType == System.Xml.XmlNodeType.Element)
            {
                if (((object)Reader.LocalName == (object)id1_ArrayOfPersistModel && string.Equals(Reader.NamespaceURI, defaultNamespace ?? id2_Item)))
                {
                    if (!ReadNull())
                    {
                        if ((object)(o) == null)
                        {
                            o = new global::System.Collections.Generic.List <global::NavigationMenuSample.Models.PersistModel>();
                        }
                        global::System.Collections.Generic.List <global::NavigationMenuSample.Models.PersistModel> a_0_0 = (global::System.Collections.Generic.List <global::NavigationMenuSample.Models.PersistModel>)o;
                        if ((Reader.IsEmptyElement))
                        {
                            Reader.Skip();
                        }
                        else
                        {
                            Reader.ReadStartElement();
                            Reader.MoveToContent();
                            int whileIterations0 = 0;
                            int readerCount0     = ReaderCount;
                            while (Reader.NodeType != System.Xml.XmlNodeType.EndElement && Reader.NodeType != System.Xml.XmlNodeType.None)
                            {
                                if (Reader.NodeType == System.Xml.XmlNodeType.Element)
                                {
                                    if (((object)Reader.LocalName == (object)id3_PersistModel && string.Equals(Reader.NamespaceURI, defaultNamespace ?? id2_Item)))
                                    {
                                        if ((object)(a_0_0) == null)
                                        {
                                            Reader.Skip();
                                        }
                                        else
                                        {
                                            a_0_0.Add(Read2_PersistModel(true, true, defaultNamespace));
                                        }
                                    }
                                    else
                                    {
                                        UnknownNode(null, @":PersistModel");
                                    }
                                }
                                else
                                {
                                    UnknownNode(null, @":PersistModel");
                                }
                                Reader.MoveToContent();
                                CheckReaderCount(ref whileIterations0, ref readerCount0);
                            }
                            ReadEndElement();
                        }
                    }
                    else
                    {
                        if ((object)(o) == null)
                        {
                            o = new global::System.Collections.Generic.List <global::NavigationMenuSample.Models.PersistModel>();
                        }
                        global::System.Collections.Generic.List <global::NavigationMenuSample.Models.PersistModel> a_0_0 = (global::System.Collections.Generic.List <global::NavigationMenuSample.Models.PersistModel>)o;
                    }
                }
                else
                {
                    throw CreateUnknownNodeException();
                }
            }
            else
            {
                UnknownNode(null, defaultNamespace ?? @":ArrayOfPersistModel");
            }
            return((object)o);
        }