本文整理汇总了Java中org.eclipse.swt.internal.cocoa.OS类的典型用法代码示例。如果您正苦于以下问题:Java OS类的具体用法?Java OS怎么用?Java OS使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
OS类属于org.eclipse.swt.internal.cocoa包,在下文中一共展示了OS类的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: sel_registerName
import org.eclipse.swt.internal.cocoa.OS; //导入依赖的package包/类
public static final long sel_registerName(String selectorName){
try {
return longValue(invokeMethod(OS.class, "sel_registerName", new Object[] { selectorName }));
}catch (Throwable throwable){
throwable.printStackTrace();
}
return 0;
}
示例2: objc_lookUpClass
import org.eclipse.swt.internal.cocoa.OS; //导入依赖的package包/类
public static final long objc_lookUpClass(String classname) throws Throwable{
return longValue(invokeMethod(OS.class, "objc_lookUpClass", new Object[] { classname }));
}
示例3: objc_allocateClassPair
import org.eclipse.swt.internal.cocoa.OS; //导入依赖的package包/类
public static final long objc_allocateClassPair(String name, long extraBytes) throws Throwable{
return longValue(invokeMethod(OS.class, "objc_allocateClassPair", new Object[] { OS.class.getField("class_NSObject").get(OS.class), name, osType(extraBytes) }));
}
示例4: class_addIvar
import org.eclipse.swt.internal.cocoa.OS; //导入依赖的package包/类
public static final boolean class_addIvar(long cls, byte[] name, long size, byte alignment, byte[] types) throws Throwable{
return boolValue(invokeMethod(OS.class, "class_addIvar", new Object[] { osType(cls), name, osType(size), new Byte(alignment), types }));
}
示例5: object_setInstanceVariable
import org.eclipse.swt.internal.cocoa.OS; //导入依赖的package包/类
public static final long object_setInstanceVariable(Object idValue, byte[] name, long value) throws Throwable{
return longValue(invokeMethod(OS.class, "object_setInstanceVariable", new Object[] { idValue , name, osType(value) }));
}
示例6: class_addMethod
import org.eclipse.swt.internal.cocoa.OS; //导入依赖的package包/类
public static final boolean class_addMethod(long cls, long name, long imp, String types) throws Throwable{
return boolValue(invokeMethod(OS.class,"class_addMethod", new Object[] { osType(cls), osType(name), osType(imp), types }));
}
示例7: objc_registerClassPair
import org.eclipse.swt.internal.cocoa.OS; //导入依赖的package包/类
public static final void objc_registerClassPair(long cls) throws Throwable{
invokeMethod(OS.class, "objc_registerClassPair", new Object[] { osType(cls) });
}
示例8: NewGlobalRef
import org.eclipse.swt.internal.cocoa.OS; //导入依赖的package包/类
public static final long NewGlobalRef( Object object ) throws Throwable{
Method method = OS.class.getMethod("NewGlobalRef", new Class[] { Object.class });
return longValue( method.invoke(OS.class, new Object[] { object }) ) ;
}
示例9: DeleteGlobalRef
import org.eclipse.swt.internal.cocoa.OS; //导入依赖的package包/类
public static final void DeleteGlobalRef( long ref ) throws Throwable{
invokeMethod(OS.class, "DeleteGlobalRef", new Object[] { osType(ref) } );
}