Questions tagged [castor]

Castor is an open source data binding framework.

Castor is an open source data binding framework for moving data from XML to Java programming language objects and from Java to databases.


Useful links

159 questions
19
votes
11 answers

Java XML Binding

What are you using for binding XML to Java? JAXB, Castor, and XMLBeans are some of the available choices. The comparisons that I've seen are all three or four years old. I'm open to other suggestions. Marshalling / unmarshalling performance and ease…
Paul Croarkin
  • 13,719
  • 14
  • 73
  • 108
12
votes
2 answers

What is the difference between Castor XML binding and JAXB binding

What is the difference between Castor XML and JAXB binding since both are binding java object to XML and vice versa. Updated : As using Castor I can do this Assume packageA.ClassA and packageB.ClassA have same attributes and class name just that…
user236501
  • 7,930
  • 23
  • 80
  • 116
9
votes
2 answers

Maven: No marketplace entries found to handle castor, antrun, and ear plugins

I am importing a maven project into Eclipse. I have the m2e plugin installed and it is pointing to maven 2.2.1 on my machine. I am getting these three errors: No marketplace entries found to handle castor-maven-plugin:1.0:generate in Eclipse No…
Eric Francis
  • 18,369
  • 25
  • 77
  • 118
8
votes
0 answers

Codehaus.org shut down today. Is there a list somewhere that says where its projects have moved to?

Or, does anyone happen to know where Castor in particular has gone, if it's still going to live somewhere? Its source is here but without any helpful additional info: https://github.com/codehaus/castor Codehaus' blog post about their history and…
lillie
  • 111
  • 1
  • 6
7
votes
1 answer

spring boot : java.lang.IllegalArgumentException: object is not an instance of declaring class

I have setup a spring boot project and using castor xml dependency to convert a POJO to xml. compile 'org.codehaus.castor:castor-xml:1.3.3' facing an issue while calling marshal method for a POJO. I have looked up other related questions on…
Vishal_Kotecha
  • 354
  • 1
  • 14
7
votes
4 answers

Sorting an XML in Java

I have an XML similar to below, which needs to be sorted using the date field.
Java Guy
  • 3,261
  • 13
  • 46
  • 55
7
votes
1 answer

Castor: Nesting elements

Given the following domain object: public class Domain { private String field1 = "one"; private String field2 = "two"; } how should the mapping.xml file be structured so the XML output looks like this:
user1052610
  • 3,730
  • 7
  • 40
  • 79
5
votes
1 answer
4
votes
2 answers

Castor XML Mapping and java.util.Map

I've been using Castor these past couple of days to try to get a little serialization going between my Java program and XML in a readable way. Though it has a few faults, Castor's automatic xml generation via reflection is actually very functional.…
duckworthd
  • 13,061
  • 13
  • 48
  • 67
4
votes
4 answers

Can Hibernate default a Null String to Empty String

In our application we are pulling data from a DB2 mainframe database. If the database has "low values" in a field, hibernate sends a "null" value in the object. This occurs even if the column is defined as "not null". As we are doing XML parsing…
markthegrea
  • 2,641
  • 5
  • 39
  • 59
4
votes
4 answers

XML Parsing / Dom Manipulation in Java

I'm trying to figure out how best to translate this: .... wer Deterministic
Babyangle86
  • 220
  • 5
  • 21
3
votes
1 answer

Spring and CastorMarshaller: add namespace to XML root

My Java application tries to get information from a webservice. The XML request needs to have the namespace specified in the XML root element (class name), but the namespace of the tags (class fields) need to be empty (null), otherwise the…
Chakrit
  • 31
  • 1
  • 3
3
votes
2 answers

Can Castor handle class generation from multiple XSDs importing from a base XSD?

I have several XSDs that reuse the same entities. For example, both the XSDs for the ProductPurchaseRequest.xsd and ProductQuoteRequest.xsd both have a tag in them to describe the product in question. For this reason I created a…
Sled
  • 16,514
  • 22
  • 110
  • 148
3
votes
1 answer

How do I get Castor to ignore certain XML fields?

I am maintaining some complex Java code and the Castor (v1.2) unmarshaling is very slow due to quite a few "missing" Java objects. See, the XML contains more fields than I require but Castor repeatedly tries to instantiate the Java objects, causing…
Richard Hurt
  • 1,759
  • 20
  • 29
3
votes
1 answer

Error creating bean with name : Scope 'request' is not active for the current thread

I have integrated SWF 2.2.1,Primefaces 2.2.1,JSF 2,Spring Security 3,Spring 3.1.0M1I and EhCache and AspectJ and Castor. I have defined beans for castor in my app-config.xml like
C4CodeE4Exe
  • 3,164
  • 8
  • 35
  • 45
1
2 3
10 11