use of org.apache.cxf.tools.corba.common.idltypes.IdlAttribute in project cxf by apache.
the class WSDLToIDLAction method createIdlAttribute.
public void createIdlAttribute(org.apache.cxf.binding.corba.wsdl.OperationType opType, String name) throws Exception {
String attrNm = name.substring(5, name.length());
IdlAttribute attr;
IdlDefn idlDef = intf.lookup(attrNm);
if (idlDef == null) {
if (name.startsWith("_get_")) {
ArgType t = opType.getReturn();
attr = IdlAttribute.create(intf, attrNm, findType(t.getIdltype()), true);
} else {
ParamType arg = opType.getParam().iterator().next();
attr = IdlAttribute.create(intf, attrNm, findType(arg.getIdltype()), false);
}
intf.addAttribute(attr);
} else {
attr = (IdlAttribute) idlDef;
if (attr.readonly() && name.startsWith("_set_")) {
attr.setReadonly(false);
}
}
}
Aggregations