Hello,
I've run into an issue that is requiring me to serialize Stanford Parser objects (all different sorts) to a file for later use. As far as I know, none of the Stanford Parser objects implement a serialization interface and I'm wondering: is there a way to serialize a Java object when the object doesn't implement serialization or ...
By way of explanation, take this value type in C#:
struct ObjRef
{
public object Value;
public ObjRef(object value) { Value = value; }
}
I can imagine an object graph where there are two boxed instances of this type, each holding a reference to the other. This is what I mean by a reference-cycle with only value-types.
My ques...
If a HTML form contains multiple input fields:
<form>
<input id="in1" type="text" value="one">
<input id="in2" type="text" value="two">
<input id="in3" type="text" value="three">
</form>
and is passed to a Spring controller as a serialized form like this:
new Ajax.Request('/doajax',
{asynchronous:true, evalScripts:true,
parame...
Is there any lib witch i can use to convert integers and floats between different architecture representation?
ie. -255 with big-endian 2byte signed integer is: 0xff7f and for 4 byte signed integer is 0xffffff7f and same with other...
I have found Binary tools package in PEAR, but it status is unmaintained and stopped at 0.3.0 version,...
I'm trying to program some AI for a game of checkers. My program is saying there are 0 moves for the white player, even though I know there are. The GetValidMoves() function is tested, and works in other areas of the code.
To try and isolate the program I saved out the problematic board-state then loaded it back up to see if I would ge...
Hi,
I'm serializing a xml string with the following code
StringReader newStringReader = new StringReader(value.Value);
try
{
using (var reader = XmlReader.Create(newStringReader))
{
newStringReader = null;
writer.WriteNode(reader, false);
...
I'm trying to get to this result while serializing XML:
<Root Name="blah">
<SomeKey>Eldad</SomeKey>
<Element>1</Element>
<Element>2</Element>
<Element>3</Element>
<Element>4</Element>
</root>
Or in other words - I'm trying to contain an array within the "root" element, alongside additional keys.
This is my crude attempt:
[...
Let's consider two classes:
Airport that has a field code.
AirportFinder with two methods:
loadCache --- reads all the airports from database and puts them into distributed cache with codes as cache keys
findByCode --- obtains instance of Airport from cache by its code.
loadCache is called during application startup and all subse...
Hi,
I'm using Flex 3.5, BlazeDS 3.2.0.3978 and EJB3 for backend. There are two RPC which are important to the problem. The first call will get a list of ThirdParty objects, this works fine. The second call happens when the user clicks on a ThirdParty, the details of this object (lazy collections) are retrieved. A single object is return...
We currently use Silverlight 4 with WCF services and try to read large arrays of users objects from service. In our code it takes about 0.5 (and less) seconds to generate 700 objects, arranged by hierarchy (a lot of loops).
And it takes about 4-5 seconds for Silverlight/WCF to communicate that data - on localhost.
I've measured timings...
Just like the title says, is there a way to check if an object is serializable, and if not, make it so at run time?
...
I want to write a Object into CSV file.
For XML we have XStream like this
So if i want to convert object to CSV do we have any such library ?
EDIT:
I want to pass my list of Bean to a method which should write all the fields of bean to CSV.
...
We needed serialization of quite large C++ class hierarchy with lots of inheritance, contraction, shared pointers, etc. I decided to use boost::serialization library.
My problem is that while compilation of this library on VS 2008 cl takes over 1 GB of RAM memory. I suppose this is caused by template-based serialization in Boost. This c...
I'm serializing a large 3d array to disk.The original data is around 50MB and GZiped output is
in Kb's size.But the operation takes around 5 sec's.I would like to optimize it for time.I was thinking weather it would be any better to use a mapped read/write since i have seen it has better performance than the usual stream writing.But don...
Using the boost serialization library I have a very simple serialize() member function, something like:
template <class Archive>
void serialize( Archive& ar, unsigned version )
{
ar & m_Searcher;
}
... and I want to keep it such simple (I don't want to use splitting in particular). But in a case of writing I want to do some...
I want to record the std::type_info of a variable so that on load I will be able to re-create the appropriate type variable.
Saving will look like this:
friend class boost::serialization::access;
template<class Archive>
void save(Archive & ar, const unsigned int version) const
{
...
ar & BOOST_SERIALIZATION_NVP(typeid(value)); ...
Hello!
As far as I understand, there is no serialization (boost::serialization, actually) support for boost::any placeholder.
Does someone know if there is a way to serialize a custom boost::any entity?
The problem here is obvious: boost::any uses template-based placeholders to store objects and typeid to check if boost::any_cast is a...
I need to generate many classes from my XML Schema (XSD) in a package (.jar).
How can I configure these classes to be serializable?
(I'm using Eclipse and JAX-B)
...
Some things in .NET are called "formatters" - BinaryFormatter, SoapFormatter.
Others are called "serializers" - XmlSerializer, DataContractSerializer.
Why the difference?
...
This question does a good job of explaining the difference in functionality between the serializers. BinaryFormatter is fast, XmlSerializer is interoperable, etc. I know that.
But what is the difference in intent? What use-case was each class designed for?
In particular:
Why did they decide to make XmlSerializer blind for private dat...