本文整理汇总了Java中com.sun.tools.internal.ws.processor.model.java.JavaSimpleType类的典型用法代码示例。如果您正苦于以下问题:Java JavaSimpleType类的具体用法?Java JavaSimpleType怎么用?Java JavaSimpleType使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
JavaSimpleType类属于com.sun.tools.internal.ws.processor.model.java包,在下文中一共展示了JavaSimpleType类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createUnwrappedParameter
import com.sun.tools.internal.ws.processor.model.java.JavaSimpleType; //导入依赖的package包/类
/**
* @param prop
* @param jaxbType
* @param block
* @return unwrapped parameter
*/
private static Parameter createUnwrappedParameter(JAXBProperty prop,
JAXBType jaxbType, Block block, JAXBStructuredType type,
JavaStructureType jst) {
QName elementName = prop.getElementName();
JavaType javaType = new JavaSimpleType(prop.getType());
JAXBElementMember eType = new JAXBElementMember(elementName, jaxbType);
JavaStructureMember jsm = new JavaStructureMember(elementName
.getLocalPart(), javaType, eType);
eType.setJavaStructureMember(jsm);
jst.add(jsm);
eType.setProperty(prop);
type.add(eType);
JAXBType t = new JAXBType(elementName, javaType, jaxbType
.getJaxbMapping(), jaxbType.getJaxbModel());
t.setUnwrapped(true);
Parameter parameter = createParameter(elementName.getLocalPart(), t, block);
parameter.setEmbedded(true);
return parameter;
}
示例2: createUnwrappedParameter
import com.sun.tools.internal.ws.processor.model.java.JavaSimpleType; //导入依赖的package包/类
/**
* @param prop
* @param jaxbType
* @param block
* @return
*/
private static Parameter createUnwrappedParameter(JAXBProperty prop,
JAXBType jaxbType, Block block, JAXBStructuredType type,
JavaStructureType jst) {
QName elementName = prop.getElementName();
JavaType javaType = new JavaSimpleType(prop.getType());
JAXBElementMember eType = new JAXBElementMember(elementName, jaxbType);
JavaStructureMember jsm = new JavaStructureMember(elementName
.getLocalPart(), javaType, eType);
eType.setJavaStructureMember(jsm);
jst.add(jsm);
eType.setProperty(prop);
type.add(eType);
JAXBType t = new JAXBType(elementName, javaType, jaxbType
.getJaxbMapping(), jaxbType.getJaxbModel());
t.setUnwrapped(true);
Parameter parameter = createParameter(elementName.getLocalPart(), t, block);
parameter.setEmbedded(true);
return parameter;
}
示例3: getResponseBeanJavaType
import com.sun.tools.internal.ws.processor.model.java.JavaSimpleType; //导入依赖的package包/类
public JavaType getResponseBeanJavaType(){
JCodeModel cm = _responseBean.getJavaType().getType().getType().owner();
if(_asyncOpType.equals(AsyncOperationType.CALLBACK)){
JClass future = cm.ref(java.util.concurrent.Future.class).narrow(cm.ref(Object.class).wildcard());
return new JavaSimpleType(new JAXBTypeAndAnnotation(future));
}else if(_asyncOpType.equals(AsyncOperationType.POLLING)){
JClass polling = cm.ref(javax.xml.ws.Response.class).narrow(_responseBean.getJavaType().getType().getType().boxify());
return new JavaSimpleType(new JAXBTypeAndAnnotation(polling));
}
return null;
}
示例4: getCallBackType
import com.sun.tools.internal.ws.processor.model.java.JavaSimpleType; //导入依赖的package包/类
public JavaType getCallBackType(){
if(_asyncOpType.equals(AsyncOperationType.CALLBACK)){
JCodeModel cm = _responseBean.getJavaType().getType().getType().owner();
JClass cb = cm.ref(javax.xml.ws.AsyncHandler.class).narrow(_responseBean.getJavaType().getType().getType().boxify());
return new JavaSimpleType(new JAXBTypeAndAnnotation(cb));
}
return null;
}
示例5: createRpcLitParameters
import com.sun.tools.internal.ws.processor.model.java.JavaSimpleType; //导入依赖的package包/类
public static List<Parameter> createRpcLitParameters(Message message, Block block, S2JJAXBModel jaxbModel, ErrorReceiverFilter errReceiver){
RpcLitStructure rpcStruct = (RpcLitStructure)block.getType();
List<Parameter> parameters = new ArrayList<Parameter>();
for(MessagePart part : message.getParts()){
if(!ModelerUtils.isBoundToSOAPBody(part))
continue;
QName name = part.getDescriptor();
TypeAndAnnotation typeAndAnn = jaxbModel.getJavaType(name);
if(typeAndAnn == null){
String msgQName = "{"+message.getDefining().getTargetNamespaceURI()+"}"+message.getName();
errReceiver.error(part.getLocator(), ModelerMessages.WSDLMODELER_RPCLIT_UNKOWNSCHEMATYPE(name.toString(),
part.getName(), msgQName));
throw new AbortException();
}
String type = typeAndAnn.getTypeClass().fullName();
type = ClassNameInfo.getGenericClass(type);
RpcLitMember param = new RpcLitMember(new QName("", part.getName()), type);
JavaType javaType = new JavaSimpleType(new JAXBTypeAndAnnotation(typeAndAnn));
param.setJavaType(javaType);
rpcStruct.addRpcLitMember(param);
Parameter parameter = ModelerUtils.createParameter(part.getName(), param, block);
parameter.setEmbedded(true);
parameters.add(parameter);
}
return parameters;
}
示例6: getJAXBType
import com.sun.tools.internal.ws.processor.model.java.JavaSimpleType; //导入依赖的package包/类
public JAXBType getJAXBType(QName qname){
JAXBMapping mapping = jaxbModel.get(qname);
if (mapping == null){
return null;
}
JavaType javaType = new JavaSimpleType(mapping.getType());
return new JAXBType(qname, javaType, mapping, jaxbModel);
}
示例7: getJavaSimpleType
import com.sun.tools.internal.ws.processor.model.java.JavaSimpleType; //导入依赖的package包/类
public static JavaSimpleType getJavaSimpleType(String className) {
return JAVA_TYPES.get(className);
}