Search Results

Search found 89 results on 4 pages for 'marshall'.

Page 3/4 | < Previous Page | 1 2 3 4  | Next Page >

  • Reversing the effects of mkimage to get an original gzipped file back

    - by Alex Marshall
    Hello, We develop for a specific embedded device at our company, and part of that is making initial root disks that get loaded onto the devices over ethernet via netboot. We've experienced some problems, and as a result, the original folder with the contents of the initial root disks was lost along with its backups, but we do still have the initrd images, that have been created by gzipping the contents of a ramdisk that's been mounted as a local loop device, and then running mkimage on the gzipped file. Is there any way to undo the effects of mkimage and obtain the original gzipped content so that we can recover the original images ?

    Read the article

  • Forcing Arrange in a Custom WPF Canvas

    - by Alex Marshall
    Hello, I'm working on a project that involves creating a custom graphical editor. The graphical editor has multiple tabs, and I want to create a preview function that will show a popup with Bitmap previews of the content of each of the tabs. However, the problem I'm running into is that the content for each of the tabs must be arranged before a proper preview can be generated for it. This means going into each of the tabs to ensure that they're rendered and arranged. Then, and only then, do the previews get properly generated, otherwise the previews have a size of 0x0. Does anybody know how to force an arrange of a content control so that I can get a properly sized preview generated ?

    Read the article

  • Getting the Assembly Qualified Name of a class in Visual Studio

    - by Alex Marshall
    Hello, I'm writing a customized reflective library for some specialized custom domain logic, and that library is going to use XML configuration files that will dynamically resolve System.Type objects at runtime. However, when writing the XML configuration files, it's a bit of a pain to write the types because they need to be fully qualified assembly names for Type.GetType() to resolve them. Is there a way to find out the AssemblyQualifiedName of an object in Visual Studio without resorting to writing a program to print them out to a file or standard out or anything like that ?

    Read the article

  • Django - Passing arguments to models through ForeignKey attributes

    - by marshall
    I've got a class like this: class Image (models.Model): ... sizes = ((90,90), (300,250)) def resize_image(self): for size in sizes: ... and another class like this: class SomeClassWithAnImage (models.Model): ... an_image = models.ForeignKey(Image) what i'd like to do with that class is this: class SomeClassWithAnImage (models.Model): ... an_image = models.ForeignKey(Image, sizes=((90,90), (150, 120))) where i'm can specify the sizes that i want the Image class to use to resize itself as a argument rather than being hard coded on the class. I realise I could pass these in when calling resize_image if that was called directly but the idea is that the resize_image method is called automatically when the object is persisted to the db. if I try to pass arguments through the foreign key declaration like this i get an error straight away. is there an easy / better way to do this before I begin hacking down into django?

    Read the article

  • Marshalling a C structure to C#

    - by Hilbert
    Hi, I don't know how to marshall this structure in Mono. typedef struct rib_struct { rib_used_t used; rib_status_t status; rib_role_t role; uint8_t conf; rib_dc_t *pending; pthread_mutex_t mutex; pthread_cond_t cond; rib_f_t *props; } rib_t; And for example, rib_dc_t is like: typedef struct rib_dc_struct { uint16_t id; uint8_t min_id; uint8_t conf; struct rib_dc_struct *next; } rib_dc_t; I don't know how to marshall the pthread structures. And the pointers... should I use IntPtr or a managed structures? How to mashall the pointer in the last struct to the struct itself? Thanks in adanvaced

    Read the article

  • The Jack LaLanne School of Sysadmins

    - by rickramsey
    Two of my childhood heroes were Tarzan and Jack LaLanne. Tarzan was an obvious choice: what boy wouldn't want to spend his days bungee jumping through the jungle with his own pack of gorillas? Jack Lalanne had a disturbing habit of wearing stretch pants, but he was so damn fit for an old guy that you couldn't help but be impressed. Especially back then, when nobody knew what a dumb bell was, much less Cross-Fit. Here's what he did to celebrate his 70th birthday. Sooner or later we all face a choice in our careers: surrender to the life of a has-been like Bruce Sprinsteen's baseball player or become an unstoppable sysadmin like Jack Lalanne. If you'd rather keep on fighting like Jack, give these resources a look. Brian Bream's blog provides specific suggestions for keeping your skills up to date. The video interviews describe the types of technologies that are challenging what you used to know. Blog: The Old School Sysadmin - A Dying Breed? by Brian Bream "The sysadmin role has been far too dependent on performing repetitive tasks and working in a reactionary mode ... the sysadmin must grow a much larger skill set to be successful. Don’t grow vertically in one technology, grow horizontally amongst many technologies." Just one of the suggestions Brian Bream provides in this excellent blog post. Video: Freeing the Sysadmin From Repetitive Tasks Interview with Marshall Choy Marshall Choy, Director of Optimized Solutions at Oracle was once a sysadmin. And a Solaris engineer. He explains what optimized solutions are, how they are developed and tested, how they handle patching, and how these vertically integrated systems impact the job and duties of a sysadmin. Video: The Oracle Database Appliance Interview with Bob Thome Bob Thome, Senior Director of Product Management, explains what makes the Database Appliance simple, reliable, and affordable, and how it could change the economies and processes of the data center. Video: Why Pinellas County Chose Oracle Exalytics Interview with Gautham Gautham (pronounced like Batman's Gotham) recently led an effort to refresh the Pinellas County hardware systems. He'll explain what they were looking for, why they chose Oracle Exalytics, how they became convinced it was the right decision, and how it changed the way they managed their data center. Video: DTrace for System Administrators Interview with Brendan Gregg This video interview will give you an idea of some of the value-add tasks you can perform when you are freed from the reactive mode that Brian Bream describes in his blog. Brendan Gregg describes the best ways for sysadmins to tune deployed applications to get more performance out of them in their particular computing environment photograph of Ford Mustang GT 500 taken at Gateway Museum copyright by Rick Ramsey -Rick Follow me on: Blog | Facebook | Twitter | Personal Twitter | YouTube | The Great Peruvian Novel

    Read the article

  • Windows Phone 7 Development &ndash; Useful Links

    - by David Turner
    Here are some excellent links for anyone developing for Windows Phone 7: J.D. Meier’s Windows Phone Developer Guidance Map – this is immense.  Also check out the Silverlight version Justin Angel’s site – some really great articles on unlocked roms, automation and Continuous Integration Windows Phone 7 Development Best Practices Wiki Jeff Blankenburg’s 31 days of Windows Phone 7 This post of Links to sample code for Windows Phone Tim Heuers blog, particularly this post of Tips and Tricks Kevin Marshall's blog, particularly the epic WP7 Development Tips Part 1 post Code Samples for Windows Phone on MSDN If you have unlocked your phone for development, then you can use the WPConnect tool to connect to the device rather than using the Zune client.  I found it useful to pin a shortcut to WPConnect in my Start Menu. The Performance Counters displayed when you debug your app on a device are useful for seeing things like frame rate and memory usage, this page on MSDN explains what the numbers mean.  Jeff Blankenburg covers this in more details on his blog I also came across this set of links to tutorials recently which looks very useful. Creating Windows Phone 7 Application and Marketplace Icons: http://expression.microsoft.com/en-us/gg317447.aspx

    Read the article

  • Are you &ldquo;completely&rdquo; connected with us?

    - by divya.malik
    In the early 1960’s Marshall McLuhan said that the world is gearing towards electronic interdependence and called this new social organization a “global village”. Well, today that global village has become the social village. We are all connecting with each other more and more every single day, across the globe. And, social media is playing a role greater than ever before. To keep up with the changing trends, and to engage more with our customers and community, our CRM Marketing team decided to adopt social media a year and a half ago. We are now all active bloggers, facebookers, and tweeters. This is a great way for you to interact with us, send us your suggestions, questions and comments. You can also get the latest content about CRM at Oracle directly through these channels. Connect with us today!!! CRM Press/Blogger Bookmarks | Twitter | Facebook | YouTube | Netvibes

    Read the article

  • Why is the concept of Marshalling called as such?

    - by chickeninabiscuit
    I've always thought that the concept of Marshalling had a bit of a funny name. My mental conception of the process would always involve an ol' wildwest gunslinging marshall who would coerce objects into serialized form at gunpoint. I just found out the real reason Marshalling is called what it's called and chuckled. Do you know the real reason, or perhaps you too are familiar with my gunslinger?

    Read the article

  • Does Marshal.ReleaseComObject call the garbage collector ?

    - by Shimrod
    Hi, I was asked this question today by a colleague, and couldn't find any clue on the Internet... Can someone tell me if calling Marshall.ReleaseComObject()directly calls the garbage collector ? As I understand it, it only removes COM references, and then the G.C. cleans memory on its next pass, but I can be mistaken... Thanks in advance for your help!

    Read the article

  • Python XML + Java XML interoperability.

    - by erb
    Hello. I need a recommendation for a pythonic library that can marshall python objects to XML(let it be a file). I need to be able read that XML later on with Java (JAXB) and unmarshall it. I know JAXB has some issues that makes it not play nice with .NET XML libraries so a recommendation on something that actually works would be great.

    Read the article

  • get text from a certain <tr> tag

    - by WideBlade
    Is there a way to get the text in a dynamic way from a certain <tr> tag in the page? e.g. I've a page with a <tr> with the value "a1". I'd like to get only the text from this <tr> tag, and echo it into the page. is this possible? here is the HTML: <html><tr id='ieconn2' > <td><table width='100%'><tr><td valign='top'><table width='100%'><tr><td><script type="text/javascript"><!-- google_ad_client = "pub-4503439170693445"; /* 300x250, created 7/21/10 */ google_ad_slot = "7608120147"; google_ad_width = 300; google_ad_height = 250; //--> </script> <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script><br>When Marshall and Lily fear they will never get pregnant, they see a specialist who can hopefully help move the process along. Meanwhile, Robin starts her new job.<br><br><b>Source: </b>CBS <br>&nbsp;</td></tr><tr><td><b>There are no foreign summaries for this episode:</b> <a href='/edit/shows/3918/episode_foreign_summary/?eid=1065002553&season=6'>Contribute</a></td></tr><tr><td><b>English Recap Available: </b> <a href='/How_I_Met_Your_Mother/episodes/1065002553?show_recap=1'>View Here</a></td></tr></table></td><td valign='top' width='250'><div align='left'> <img alt='How I Met Your Mother season 6 episode 13' src="http://images.tvrage.com/screencaps/20/3918/1065002553.jpg" width="248" border='0' > </div><div align='center'><a href='/How_I_Met_Your_Mother/episodes/1065002553?gallery=1'>6 gallery images</a></div></td></tr></table></td></tr><tr> <td background='/_layout_v3/buttons/title.jpg' height='39' width='631' align='center'> <table width='100%' cellpadding='0' cellspacing='0' style='margin: 1px 1px 1px 1px;'> <tr> <td align='left' style='cursor: pointer;' onclick="SwitchHeader('ieconn3','iehide3','26')" width='90'>&nbsp;<span style='font-size: 15px; font-weight: bold; color: black; padding-left: 8px;' id='iehide3'><img src='/_layout_v3/misc/minus.gif' width='26'></span></td> <td align='center' style='cursor: pointer;' onclick="SwitchHeader('ieconn3','iehide3','26')" ><h5 class='nospace'>Sponsored Links</h5><a name=''></a></td> <td align='left' width='90' >&nbsp;</td></tr></table></td> </tr></html> All I want to get is this text: "When Marshall and Lily fear they will never get pregnant, they see a specialist who can hopefully help move the process along. Meanwhile, Robin starts her new job. "

    Read the article

  • unit/integration testing web service proxy client

    - by cori
    I'm rewriting a PHP client/proxy library that provides an interface to a SOAP-based .Net webservice, and in the process I want to add some unit and integration tests so future modifications are less risky. The work the library I'm working on performs is to marshall the calls to the web service and do a little reorganizing of the responses to present a slightly more -object-oriented interface to the underlying service. Since this library is little else than a thin layer on top of web service calls, my basic assumption is that I'll really be writing integration tests more than unit tests - for example, I don't see any reason to mock away the web service - the work that's performed by the code I'm working on is very light; it's almost passing the response from the service right back to its consumer. Most of the calls are basic CRUD operations: CreateRole(), CreateUser(), DeleteUser(), FindUser(), &ct. I'll be starting from a known database state - the system I'm using for these tests is isolated for testing purposes, so the results will be more or less predictable. My question is this: is it natural to use web service calls to confirm the results of operations within the tests and to reset the state of the application within the scope of each test? Here's an example: One test might be createUserReturnsValidUserId() and might go like this: public function createUserReturnsValidUserId() { // we're assuming a global connection to the service $newUserId = $client->CreateUser("user1"); assertNotNull($newUserId); assertNotNull($client->FindUser($newUserId); $client->deleteUser($newUserId); } So I'm creating a user, making sure I get an ID back and that it represents a user in the system, and then cleaning up after myself (so that later tests don't rely on the success or failure of this test w/r/t the number of users in the system, for example). However this still seems pretty fragile - lots of dependencies and opportunities for tests to fail and effect the results of later tests, which I definitely want to avoid. Am I missing some options of ways to decouple these tests from the system under test, or is this really the best I can do? I think this is a fairly general unit/integration testing question, but if it matters I'm using PHPUnit for the testing framework.

    Read the article

  • Using XSLT for messaging instead of marshalling/unmarshalling Java message objects

    - by Joost van Stuijvenberg
    So far I have been using either handmade or generated (e.g. JAXB) Java objects as 'carriers' for messages in message processing software such as protocol converters. This often leads to tedious programming, such as copying/converting data from one system's message object to an instance of another's system message object. And it sure brings in lots of Java code with getters and setters for each message attribute, validation code, etc. I was wondering whether it would be a good idea to convert one system's XML message into another system's format - or even convert requests into responses from the same system - using XSLT. This would mean I would no longer have to unmarshall XML streams to Java objects, copy/convert data using Java and marshall the resulting message object to another XML stream. Since each message may actually have a purpose I would 'link' the message (and the payload it contains in its properties or XML elements/attributes) to EXSLT functions. This would change my design approach from an imperative to a declarative style. Has anyone done this before and, if so, what are your experiences? Does the reduced amount of Java 'boiler plate' code weigh up to the increased complexity of (E)XSLT?

    Read the article

  • JAX-RS JSON java.util.Date Unmarshall

    - by user229498
    Hi, I'm using Jersey (jax-rs), to build a REST rich application. Everything is great, but I really don't understand how to set in JSON Marshalling and Unmarshalling converting option for dates and numbers. I have a User class: @XmlRootElement public class User { private String username; private String password; private java.util.Date createdOn; // ... getters and setters } When createdOn property is serialized, a string like this: '2010-05-12T00:00:00+02:00', but I need to choose date Pattern both, to marshall and unmarshall. Someone knows hot to do that? Thank's a lot, Davide.

    Read the article

  • JAXB, marshalling sub-class that has the same rootNode name as the superclass

    - by SCdF
    Let's say I have this: public class Foo { private String value; // <snip> getters and setters, constructors etc } And I also have this: public class Bar extends Foo { private String anotherValue; // <snip> getters and setters, constructors etc } I want to be able to marshall this to a Bar object: <foo> <value>smang</value> <anotherValue>wratz</anotherValue> </foo> I'm not in a position to check right now, but if I change the @XmlRootNode name of Bar to 'foo' will that work? Do I have to do anything more clever than that?

    Read the article

  • JAXB appending unneeded namespace declarations to tags

    - by jb
    I'm implementing a homebrew subprotocol of XMPP, and i'm using combination of StAX and JAXB for parsing/marshalling mesages. And when I marshall a message I end up with loads of unneded namespace declarations: <ns2:auth xmlns:ns2="urn:ietf:params:xml:ns:ilf-auth" xmlns:ns4="ilf:iq:experiment:power" xmlns:ns3="ilf:iq:experiment:init" xmlns:ns5="ilf:iq:experiment:values" xmlns:ns6="ilf:iq:experiment:result" xmlns:ns7="ilf:iq:experiment:stop" xmlns:ns8="ilf:iq:experiment:end"> compton@ilf</ns2:auth> instead of: <ns:auth xmlns:ns="urn:ietf:params:xml:ns:ilf-auth>compton@ilf</ns:auth> Is there any way to turn that of? All these namespaces are used in different messages that get marshalled/unmarshalled by JAXB, but every message uses one namespace. PS. I am not an XML expert please dont rant me if I did some stupid mistake ;)

    Read the article

  • marshal Map<String, String> to .xml

    - by richardl
    If I have Map setup like: map.put("foo", "123"); map.put("bar", "456"); map.put("baz", "789"); then I want to do something like: for (String key : map.keySet().toArray(new String[0])) { // marshall out to .xml a tag with the name key and the // value map.get(key) } So what it will marshal out is something like: <map> <foo>123</foo> <bar>456</bar> <baz>789</baz> </map> Can I do this with some fancy JAXB annotations or is there something else that lends it self to dynamic element names? TIA

    Read the article

  • Need to interface to a C++ DLL

    - by Pedro
    Hi, I need to call a C++ API from C#. I have been able to call the API, but the char[] parameters do not seem to be marshalling correctly. Here's the C++ signature: Create2ptModel(double modelPowers[2], double modelDacs[2], int pclRange[2], double targetPowers[32], double *dacAdjustFactor, unsigned short powerRampFactors[32], BOOL bPCLDacAdjusted[32], char calibrationModel[32], char errMsg[1024]) and this is how I am trying to call it from C# [DllImport("AlgorithmsLib.dll", EntryPoint = "_Create2ptModel@36", ExactSpelling = true, CallingConvention = CallingConvention.StdCall, CharSet = CharSet.Auto)] private static extern AlgorithmStatus Create2ptModel( double[] modelPowers, double[] modelDacs, int[] pclRange, double[] targetPowers, ref double dacAdjustFactor, ushort[] powerRampFactors, bool[] bPCLDacAdjusted, /**/char[] calibrationModel, char[] errMsg/**/); Any idea of how I can marshall it correctly? Thanks in advance!

    Read the article

  • WebCenter Customer Spotlight: Texas Industries, Inc.

    - by me
    Author: Peter Reiser - Social Business Evangelist, Oracle WebCenter  Solution SummaryTexas Industries, Inc. (TXI) is a leading supplier of cement, aggregate, and consumer product building materials for residential, commercial, and public works projects. TXI is based in Dallas and employs around 2,000 employees. The customer had the challenge of decentralized and manual processes for entering 180,000 vendor invoices annually.  Invoice entry was a time- and resource-intensive process that entailed significant personnel requirements. TXI implemented a centralized solution leveraging Oracle WebCenter Imaging, a smart routing solution that enables users to capture invoices electronically with Oracle WebCenter Capture and Oracle WebCenter Forms Recognition to send  the invoices through to Oracle Financials for approvals and processing.  TXI significantly lowered resource needs for payable processing,  increase productivity by 80% and reduce invoice processing cycle times by 84%—from 20 to 30 days to just 3 to 5 days, on average. Company OverviewTexas Industries, Inc. (TXI) is a leading supplier of cement, aggregate, and consumer product building materials for residential, commercial, and public works projects. With operating subsidiaries in six states, TXI is the largest producer of cement in Texas and a major producer in California. TXI is a major supplier of stone, sand, gravel, and expanded shale and clay products, and one of the largest producers of bagged cement and concrete  products in the Southwest. Business ChallengesTXI had the challenge of decentralized and manual processes for entering 180,000 vendor invoices annually.  Invoice entry was a time- and resource-intensive process that entailed significant personnel requirements. Their business objectives were: Increase the efficiency of core business processes, such as invoice processing, to support the organization’s desire to maintain its role as the Southwest’s leader in delivering high-quality, low-cost products to the construction industry Meet the audit and regulatory requirements for achieving Sarbanes-Oxley (SOX) compliance Streamline entry of 180,000 invoices annually to accelerate processing, reduce errors, cut invoice storage and routing costs, and increase visibility into payables liabilities Solution DeployedTXI replaced a resource-intensive, paper-based, decentralized process for invoice entry with a centralized solution leveraging Oracle WebCenter Imaging 11g. They worked with the Oracle Partner Keste LLC to develop a smart routing solution that enables users to capture invoices electronically with Oracle WebCenter Capture and then uses Oracle WebCenter Forms Recognition and the Oracle WebCenter Imaging workflow to send the invoices through to Oracle Financials for approvals and processing. Business Results Significantly lowered resource needs for payable processing through centralization and improved efficiency  Enabled the company to process invoices faster and pay bills earlier, allowing it to take advantage of additional vendor discounts Tracked to increase productivity by 80% and reduce invoice processing cycle times by 84%—from 20 to 30 days to just 3 to 5 days, on average Achieved a 25% reduction in paper invoice storage costs now that invoices are captured digitally, and enabled a 50% reduction in shipping costs, as the company no longer has to send paper invoices between headquarters and production facilities for approvals “Entering and manually processing more than 180,000 vendor invoices annually was time and labor intensive. With Oracle Imaging and Process Management, we have automated and centralized invoice entry and processing at our corporate office, improving productivity by 80% and reducing invoice processing cycle times by 84%—a very important efficiency gain.” Terry Marshall, Vice President of Information Services, Texas Industries, Inc. Additional Information TXI Customer Snapshot Oracle WebCenter Content Oracle WebCenter Capture Oracle WebCenter Forms Recognition

    Read the article

  • How to use Parcel in Android?

    - by Mike
    I'm trying to use Parcel to write and then read back a Parcelable. For some reason, when I read the object back from the file, it's coming back as null. public void testFoo() { final Foo orig = new Foo("blah blah"); // Wrote orig to a parcel and then byte array final Parcel p1 = Parcel.obtain(); p1.writeValue(orig); final byte[] bytes = p1.marshall(); // Check to make sure that the byte array seems to contain a Parcelable assertEquals(4, bytes[0]); // Parcel.VAL_PARCELABLE // Unmarshall a Foo from that byte array final Parcel p2 = Parcel.obtain(); p2.unmarshall(bytes, 0, bytes.length); final Foo result = (Foo) p2.readValue(Foo.class.getClassLoader()); assertNotNull(result); // FAIL assertEquals( orig.str, result.str ); } protected static class Foo implements Parcelable { protected static final Parcelable.Creator<Foo> CREATOR = new Parcelable.Creator<Foo>() { public Foo createFromParcel(Parcel source) { final Foo f = new Foo(); f.str = (String) source.readValue(Foo.class.getClassLoader()); return f; } public Foo[] newArray(int size) { throw new UnsupportedOperationException(); } }; public String str; public Foo() { } public Foo( String s ) { str = s; } public int describeContents() { return 0; } public void writeToParcel(Parcel dest, int ignored) { dest.writeValue(str); } } What am I missing? UPDATE: To simplify the test I've removed the reading and writing of files in my original example.

    Read the article

  • Most efficient way to send images across processes

    - by Heinrich Ulbricht
    Goal Pass images generated by one process efficiently and at very high speed to another process. The two processes run on the same machine and on the same desktop. The operating system may be WinXP, Vista and Win7. Detailled description The first process is solely for controlling the communication with a device which produces the images. These images are about 500x300px in size and may be updated up to several hundred times per second. The second process needs these images to display them. The first process uses a third party API to paint the images from the device to a HDC. This HDC has to be provided by me. Note: There is already a connection open between the two processes. They are communicating via anonymous pipes and share memory mapped file views. Thoughts How would I achieve this goal with as little work as possible? And I mean both work for me and the computer. I am using Delphi, so maybe there is some component available for doing this? I think I could always paint to any image component's HDC, save the content to memory stream, copy the contents via the memory mapped file, unpack it on the other side and paint it there to the destination HDC. I also read about a IPicture interface which can be used to marshall images. What are your ideas? I appreciate every thought on this!

    Read the article

  • JAXB, how to marshal without a namespace

    - by Alvin
    I have a fairly large repetitive XML to create using JAXB. Storing the whole object in the memory then do the marshaling takes too much memory. Essentially, my XML looks like this: <Store> <item /> <item /> <item /> ..... </Store> Currently my solution to the problem is to "hard code" the root tag to an output stream, and marshal each of the repetitive element one by one: aOutputStream.write("<?xml version="1.0"?>") aOutputStream.write("<Store>") foreach items as item aMarshaller.marshall(item, aOutputStream) end aOutputStream.write("</Store>") aOutputStream.close() Somehow the JAXB generate the XML like this <Store xmlns="http://stackoverflow.com"> <item xmlns="http://stackoverflow.com"/> <item xmlns="http://stackoverflow.com"/> <item xmlns="http://stackoverflow.com"/> ..... </Store> Although this is a valid XML, but it just look ugly, so I'm wonder is there any way to tell the marshaller not to put namespace for the item elements? Or is there better way to use JAXB to serialize to XML chunk by chunk?

    Read the article

  • JAXB code generation: how to remove a zero occurrence field?

    - by reef
    Hi all, I use JAXB 2.1 to generate Java classes from several XSD files, and I have a problem related to complex type restriction. On of the restrictions modifies the occurence configuration from minOccurs="0" maxOccurs="unbounded" to minOccurs="0" maxOccurs="0". Thus this field is not needed anymore in the restricted type. But actually JAXB generates the restricted class with a [0..1] cardinality instead of 0. By the way the generation is tuned with <xjc:treatRestrictionLikeNewType / so that a XSD restriction is not mapped to a Java class inheritance. Here is an example: Here is the way a field is defined in a complex type A: <element name="qualifier" type="CR" maxOccurs="unbounded" minOccurs="0"/ Here is the way the same field is restricted in another complex type B that restricts A: <element name="qualifier" type="CR" minOccurs="0" maxOccurs="0"/ In the A generated class I have: @XmlElement(name = "qualifier") protected List<CR qualifiers; And in the B generated class I have: protected CR qualifiers; With my poor understanding of JAXB the absence of the XmlElement annotation tells JAXB not to marshall/unmarshall this field. Am I wrong? If I am right is there a way to tell JAXB not to generate the qualifiers field at all? This would be in my opinion a much better generation as it respects the constraints. Any idea, thougths on the topic? Thanks!!

    Read the article

< Previous Page | 1 2 3 4  | Next Page >