This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<account> | |
<accountKey> | |
<location>Texas</location> | |
<number>6086510</number> | |
<code>06</code> | |
</accountKey> | |
</account> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<query xmlns="urn:Account-WSDL"> | |
<serviceContext> | |
<externalUserName>USR</externalUserName> | |
</serviceContext> | |
<account> | |
<accountKey> | |
<location>Texas</location> | |
<number>6086510</number> | |
<code>06</code> | |
</accountKey> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@XmlAccessorType(XmlAccessType.FIELD) | |
@XmlType(name = "MethodInput", propOrder = { | |
"serviceContext", | |
"account" | |
}) | |
public class MethodInput{ | |
@XmlElement(required = true) | |
protected ServiceContext serviceContext; | |
@XmlElement(required = true) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class JaxbUnmarshallerWithDocBuilder { | |
public static void main(String args[]){ | |
try{ | |
JAXBContext jc = JAXBContext.newInstance("com.kartikshah.api.account.wsdl"); | |
Unmarshaller u = jc.createUnmarshaller(); | |
DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); | |
dbf.setNamespaceAware(true); | |
DocumentBuilder db = dbf.newDocumentBuilder(); | |
Document doc = db.parse(JaxbUnmarshallerWithDocBuilder.class.getResource("account.xml")); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@XmlRootElement | |
@XmlAccessorType(XmlAccessType.FIELD) | |
@XmlType(name = "Account", propOrder = { | |
"accountKey", // .. other fields omitted for brevity | |
}) | |
public class Account{ | |
protected AccountKey accountKey; | |
// ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@XmlRegistry | |
public class ObjectFactory { | |
// ... | |
private final static QName Query1_QNAME = new QName("urn:Account-WSDL", "query"); | |
// ... | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class JaxbUnmarshallerMethodInput{ | |
public static void main(String args[]){ | |
try{ | |
JAXBContext jc = JAXBContext.newInstance("com.kartikshah.api.account.wsdl"); | |
Unmarshaller u = jc.createUnmarshaller(); | |
JAXBElement element = (JAXBElement)u.unmarshal(JaxbUnmarshallerMethodInput.class.getResource("query.xml")); | |
MethodInput methodInput = (MethodInput)element.getValue(); | |
Account account = methodInput.getAccount(); | |
ServiceContext context = methodInput.getServiceContext(); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<path id="wlst.class.path"> | |
<fileset dir="${bea.home}/Oracle_OSB1/lib"> | |
<include name="sb-kernel-api.jar" /> | |
<include name="alsb.jar" /> | |
</fileset> | |
<fileset dir="${bea.home}/Oracle_OSB1/modules"> | |
<include name="com.bea.common.configfwk_1.3.0.0.jar" /> | |
</fileset> | |
<fileset dir="${wl.home}/server/lib"> | |
<include name="weblogic.jar" /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(fn [& fns] | |
(fn [& args] | |
(map #(apply % args) fns))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(fn [xs] | |
(let [m (group-by (fn [x] x) xs)] | |
(zipmap (keys m) (map count (vals m))))) |