org.simpleframework.xml.Transient Java Examples
The following examples show how to use
org.simpleframework.xml.Transient.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: FieldScanner.java From simplexml with Apache License 2.0 | 5 votes |
/** * This reflectively checks the annotation to determine the type * of annotation it represents. If it represents an XML schema * annotation it is used to create a <code>Contact</code> which * can be used to represent the field within the source object. * * @param field the field that the annotation comes from * @param label the annotation used to model the XML schema * @param list this is the list of annotations on the field */ private void scan(Field field, Annotation label, Annotation[] list) { if(label instanceof Attribute) { process(field, label, list); } if(label instanceof ElementUnion) { process(field, label, list); } if(label instanceof ElementListUnion) { process(field, label, list); } if(label instanceof ElementMapUnion) { process(field, label, list); } if(label instanceof ElementList) { process(field, label, list); } if(label instanceof ElementArray) { process(field, label, list); } if(label instanceof ElementMap) { process(field, label, list); } if(label instanceof Element) { process(field, label, list); } if(label instanceof Version) { process(field, label, list); } if(label instanceof Text) { process(field, label, list); } if(label instanceof Transient) { remove(field, label); } }
Example #2
Source File: MethodScanner.java From simplexml with Apache License 2.0 | 5 votes |
/** * This reflectively checks the annotation to determine the type * of annotation it represents. If it represents an XML schema * annotation it is used to create a <code>Contact</code> which * can be used to represent the method within the source object. * * @param method the method that the annotation comes from * @param label the annotation used to model the XML schema * @param list this is the list of annotations on the method */ private void scan(Method method, Annotation label, Annotation[] list) throws Exception { if(label instanceof Attribute) { process(method, label, list); } if(label instanceof ElementUnion) { process(method, label, list); } if(label instanceof ElementListUnion) { process(method, label, list); } if(label instanceof ElementMapUnion) { process(method, label, list); } if(label instanceof ElementList) { process(method, label, list); } if(label instanceof ElementArray) { process(method, label, list); } if(label instanceof ElementMap) { process(method, label, list); } if(label instanceof Element) { process(method, label, list); } if(label instanceof Version) { process(method, label, list); } if(label instanceof Text) { process(method, label, list); } if(label instanceof Transient) { remove(method, label, list); } }
Example #3
Source File: DefaultWithParametersInGetterTest.java From simplexml with Apache License 2.0 | 4 votes |
@Transient public String getWithParams(int foo) { return "foo"; }
Example #4
Source File: DefaultAnnotationTest.java From simplexml with Apache License 2.0 | 4 votes |
@Transient public String getSecret() { return secret; }
Example #5
Source File: DefaultAnnotationTest.java From simplexml with Apache License 2.0 | 4 votes |
@Transient public void setSecret(String secret) { this.secret = secret; }