本文整理汇总了Java中org.omg.CORBA.TCKind._tk_wstring方法的典型用法代码示例。如果您正苦于以下问题:Java TCKind._tk_wstring方法的具体用法?Java TCKind._tk_wstring怎么用?Java TCKind._tk_wstring使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.omg.CORBA.TCKind
的用法示例。
在下文中一共展示了TCKind._tk_wstring方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: insert_wstring
import org.omg.CORBA.TCKind; //导入方法依赖的package包/类
public void insert_wstring(String value)
throws org.omg.DynamicAny.DynAnyPackage.TypeMismatch,
org.omg.DynamicAny.DynAnyPackage.InvalidValue
{
if (status == STATUS_DESTROYED) {
throw wrapper.dynAnyDestroyed() ;
}
if (any.type().kind().value() != TCKind._tk_wstring)
throw new TypeMismatch();
if (value == null)
throw new InvalidValue();
// Throw InvalidValue if this is a bounded string and the length is exceeded
try {
if (any.type().length() > 0 && any.type().length() < value.length())
throw new InvalidValue();
} catch (BadKind bad) { // impossible
}
any.insert_wstring(value);
}
示例2: TypeCodeImpl
import org.omg.CORBA.TCKind; //导入方法依赖的package包/类
public TypeCodeImpl(ORB orb, int creationKind)
// for primitive types
{
this(orb);
// private API. dont bother checking that
// (creationKind < 0 || creationKind > typeTable.length)
_kind = creationKind;
// do initialization for special cases
switch (_kind) {
case TCKind._tk_objref:
{
// this is being used to create typecode for CORBA::Object
setId("IDL:omg.org/CORBA/Object:1.0");
_name = "Object";
break;
}
case TCKind._tk_string:
case TCKind._tk_wstring:
{
_length =0;
break;
}
case TCKind._tk_value:
{
_concrete_base = null;
break;
}
}
}
示例3: length
import org.omg.CORBA.TCKind; //导入方法依赖的package包/类
public int length()
throws BadKind
{
switch (_kind) {
case tk_indirect:
return indirectType().length();
case TCKind._tk_string:
case TCKind._tk_wstring:
case TCKind._tk_sequence:
case TCKind._tk_array:
return _length;
default:
throw new BadKind();
}
}
示例4: get_wstring
import org.omg.CORBA.TCKind; //导入方法依赖的package包/类
public String get_wstring()
throws org.omg.DynamicAny.DynAnyPackage.TypeMismatch,
org.omg.DynamicAny.DynAnyPackage.InvalidValue
{
if (status == STATUS_DESTROYED) {
throw wrapper.dynAnyDestroyed() ;
}
if (any.type().kind().value() != TCKind._tk_wstring)
throw new TypeMismatch();
return any.extract_wstring();
}
示例5: ORB
import org.omg.CORBA.TCKind; //导入方法依赖的package包/类
protected ORB()
{
// Initialize logging first, since it is needed nearly
// everywhere (for example, in TypeCodeImpl).
wrapperMap = new ConcurrentHashMap();
wrapper = ORBUtilSystemException.get( this,
CORBALogDomains.RPC_PRESENTATION ) ;
omgWrapper = OMGSystemException.get( this,
CORBALogDomains.RPC_PRESENTATION ) ;
typeCodeMap = new HashMap();
primitiveTypeCodeConstants = new TypeCodeImpl[] {
new TypeCodeImpl(this, TCKind._tk_null),
new TypeCodeImpl(this, TCKind._tk_void),
new TypeCodeImpl(this, TCKind._tk_short),
new TypeCodeImpl(this, TCKind._tk_long),
new TypeCodeImpl(this, TCKind._tk_ushort),
new TypeCodeImpl(this, TCKind._tk_ulong),
new TypeCodeImpl(this, TCKind._tk_float),
new TypeCodeImpl(this, TCKind._tk_double),
new TypeCodeImpl(this, TCKind._tk_boolean),
new TypeCodeImpl(this, TCKind._tk_char),
new TypeCodeImpl(this, TCKind._tk_octet),
new TypeCodeImpl(this, TCKind._tk_any),
new TypeCodeImpl(this, TCKind._tk_TypeCode),
new TypeCodeImpl(this, TCKind._tk_Principal),
new TypeCodeImpl(this, TCKind._tk_objref),
null, // tk_struct
null, // tk_union
null, // tk_enum
new TypeCodeImpl(this, TCKind._tk_string),
null, // tk_sequence
null, // tk_array
null, // tk_alias
null, // tk_except
new TypeCodeImpl(this, TCKind._tk_longlong),
new TypeCodeImpl(this, TCKind._tk_ulonglong),
new TypeCodeImpl(this, TCKind._tk_longdouble),
new TypeCodeImpl(this, TCKind._tk_wchar),
new TypeCodeImpl(this, TCKind._tk_wstring),
new TypeCodeImpl(this, TCKind._tk_fixed),
new TypeCodeImpl(this, TCKind._tk_value),
new TypeCodeImpl(this, TCKind._tk_value_box),
new TypeCodeImpl(this, TCKind._tk_native),
new TypeCodeImpl(this, TCKind._tk_abstract_interface)
} ;
monitoringManager =
MonitoringFactories.getMonitoringManagerFactory( ).
createMonitoringManager(
MonitoringConstants.DEFAULT_MONITORING_ROOT,
MonitoringConstants.DEFAULT_MONITORING_ROOT_DESCRIPTION);
}
示例6: create_wstring_tc
import org.omg.CORBA.TCKind; //导入方法依赖的package包/类
public TypeCode create_wstring_tc(int bound) {
return new TypeCodeImpl(this, TCKind._tk_wstring, bound);
}
示例7: ORB
import org.omg.CORBA.TCKind; //导入方法依赖的package包/类
protected ORB()
{
// Initialize logging first, since it is needed nearly
// everywhere (for example, in TypeCodeImpl).
wrapperMap = new ConcurrentHashMap<>();
wrapper = ORBUtilSystemException.get( this,
CORBALogDomains.RPC_PRESENTATION ) ;
omgWrapper = OMGSystemException.get( this,
CORBALogDomains.RPC_PRESENTATION ) ;
typeCodeMap = new HashMap<>();
primitiveTypeCodeConstants = new TypeCodeImpl[] {
new TypeCodeImpl(this, TCKind._tk_null),
new TypeCodeImpl(this, TCKind._tk_void),
new TypeCodeImpl(this, TCKind._tk_short),
new TypeCodeImpl(this, TCKind._tk_long),
new TypeCodeImpl(this, TCKind._tk_ushort),
new TypeCodeImpl(this, TCKind._tk_ulong),
new TypeCodeImpl(this, TCKind._tk_float),
new TypeCodeImpl(this, TCKind._tk_double),
new TypeCodeImpl(this, TCKind._tk_boolean),
new TypeCodeImpl(this, TCKind._tk_char),
new TypeCodeImpl(this, TCKind._tk_octet),
new TypeCodeImpl(this, TCKind._tk_any),
new TypeCodeImpl(this, TCKind._tk_TypeCode),
new TypeCodeImpl(this, TCKind._tk_Principal),
new TypeCodeImpl(this, TCKind._tk_objref),
null, // tk_struct
null, // tk_union
null, // tk_enum
new TypeCodeImpl(this, TCKind._tk_string),
null, // tk_sequence
null, // tk_array
null, // tk_alias
null, // tk_except
new TypeCodeImpl(this, TCKind._tk_longlong),
new TypeCodeImpl(this, TCKind._tk_ulonglong),
new TypeCodeImpl(this, TCKind._tk_longdouble),
new TypeCodeImpl(this, TCKind._tk_wchar),
new TypeCodeImpl(this, TCKind._tk_wstring),
new TypeCodeImpl(this, TCKind._tk_fixed),
new TypeCodeImpl(this, TCKind._tk_value),
new TypeCodeImpl(this, TCKind._tk_value_box),
new TypeCodeImpl(this, TCKind._tk_native),
new TypeCodeImpl(this, TCKind._tk_abstract_interface)
} ;
monitoringManager =
MonitoringFactories.getMonitoringManagerFactory( ).
createMonitoringManager(
MonitoringConstants.DEFAULT_MONITORING_ROOT,
MonitoringConstants.DEFAULT_MONITORING_ROOT_DESCRIPTION);
}
示例8: create_wstring_tc
import org.omg.CORBA.TCKind; //导入方法依赖的package包/类
/**
* Create a TypeCode for a wide string.
*
* @param bound the bound for the string.
* @return the requested TypeCode.
*/
public synchronized TypeCode create_wstring_tc(int bound)
{
checkShutdownState();
return new TypeCodeImpl(this, TCKind._tk_wstring, bound);
}