Java Doc for Link.java in  » Database-ORM » ODAL » com » completex » objective » components » persistency » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Database ORM » ODAL » com.completex.objective.components.persistency 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.completex.objective.components.persistency.ParentBase
      com.completex.objective.components.persistency.Link

All known Subclasses:   com.completex.objective.components.persistency.ChainedLink,  com.completex.objective.components.persistency.InlineLink,
Link
public class Link extends ParentBase implements Parent,Serializable,Cloneable,Mappable(Code)
Represents tree structure used to create Query trees as well as PersistentObject trees.
author:
   Gennady Krizhevsky

Inner Class :public static class RelationshipType
Inner Class :public static class InlineMode

Field Summary
final public static  StringINLINE_INNER
    
final public static  StringINLINE_OUTER
    
final public static  InlineModeINNER_JOIN_MODE
    
final public static  RelationshipTypeMANY_TO_MANY
    
final public static  RelationshipTypeMANY_TO_ONE
    
final public static  RelationshipTypeONE_TO_MANY
    
final public static  RelationshipTypeONE_TO_ONE
    
final public static  InlineModeOUTER_JOIN_MODE
    
final public static  StringSEP
    
final public static  StringTAG_QUERY
    
final public static  StringTAG_QUERY_CLASS
    
protected transient  InlineModeinlineMode
    
protected transient  int[]parentIndeces
    
final static  longserialVersionUID
    
protected transient  int[]thisIndeces
    

Constructor Summary
public  Link()
    
public  Link(Map map)
    
public  Link(String name)
    
public  Link(String name, Object result)
    
public  Link(String name, Object result, boolean adHoc)
    
public  Link(Query query, int[] parentIndeces, int thisIndeces)
    
public  Link(Query query, int[] parentIndeces, int thisIndeces, String name)
    
public  Link(Link source)
    

Method Summary
public  voidaddNotNullToResultCollection(Object value)
    
public  voidaddParentPath(List parentPath)
    
public  voidaddToPath(String name)
    
public  voidaddToResultCollection(Object value)
    
public  Objectclone()
    
 ListcloneList(List list)
    
public  LinkcopyAll(Link source)
    
public  voidcopyResults(Link from)
    
public static  voidcopyResults(Link from, Link to, int level)
    
public  voidcopyResultsOneLevel(Link from)
    
public  voidfromMap(Map map)
    
protected  int[]fromMapToIntArray(PropertyMap map, String tag)
    
public  intgetDependencyIndex()
    
public  InlineModegetInlineMode()
    
public  LifeCycleControllergetLifeCycleController()
    
public  StringgetName()
    
public  int[]getParentIndeces()
     Returns parent indeces - indeces of the parent persistent object which contains a link [pointing to itself.
public  ListgetPath()
    
public  StringgetPathString()
    
public  QuerygetQuery()
    
public  ObjectgetResult()
    
public  CollectiongetResultAsCollection()
    
public  int[]getThisIndeces()
     Returns "this indeces" - indeces of this link query's SingularResultFactory which values are mapped to corresponding parent ones.
public  booleanisAdHoc()
    
public  booleanisCascadeDelete()
    
public  booleanisCascadeInsert()
    
public  booleanisCascadeUpdate()
    
public  booleanisEndOfChain()
     Returns true is this link is end of link chain.
public  booleanisInline()
    
public  booleanisInner()
    
public  booleanisInsertBeforeParent()
    
public  booleanisLazyRetrieval()
    
public  booleanisOuter()
    
public  booleanisRetrieved()
    
public  booleanisTreatNullAsRemove()
    
public  LinknewInstance()
    
protected  LinknewInstance0(Query query)
    
public static  Stringpath2string(List path)
    
public  voidpopulateClonedCollection(Collection collection)
    
public  voidpopulateClonedMap(Map map)
    
public  voidsetAdHoc(boolean adHoc)
    
public  LinksetCascadeAll()
     Sets cascadeDelete = true; cascadeInsert = true; cascadeUpdate = true.
public  voidsetCascadeDelete(boolean cascadeDelete)
    
public  voidsetCascadeInsert(boolean cascadeInsert)
    
public  voidsetCascadeUpdate(boolean cascadeUpdate)
    
public  voidsetDependencyIndex(int dependencyIndex)
    
public  voidsetEndOfChain(boolean endOfChain)
     If true - this link is end of link chain.
public  voidsetInlineMode(InlineMode inlineMode)
    
public  voidsetInlineMode(String childName, InlineMode inlineMode)
    
public  voidsetInsertBeforeParent(boolean insertBeforeParent)
    
public  voidsetLazyRetrieval(boolean lazyRetrieval)
    
public  voidsetLifeCycleController(LifeCycleController lifeCycleController)
    
public  voidsetName(String name)
     Sets link name.
public  voidsetParentIndeces(int[] parentIndeces)
     Sets parent indeces - indeces of the parent persistent object which contains a link [pointing to itself.
public  voidsetPath(String pathString)
    
 voidsetPath(List path)
    
public  voidsetQuery(Query query)
    
public  voidsetRelationshipToParent(RelationshipType relationshipType)
    
public  voidsetResult(Object result)
    
public  voidsetRetrieved(boolean retrieved)
    
public  voidsetThisIndeces(int[] thisIndeces)
     Sets "this indeces" - indeces of this link query's SingularResultFactory which values are mapped to corresponding parent ones.
public  voidsetTreatNullAsRemove(boolean treatNullAsRemove)
    
public static  Liststring2path(String pathString)
    
public static  InlineModetoInlineMode(String modeName)
    
public  LinktoLink()
    
public  MaptoMap()
    
protected  voidtoMapArray(Map map, String tag, int[] array)
    
public  StringtoString()
    
public  StringtoSummaryString()
    
public  LinkunsetCascadeAll()
     Unsets cascadeDelete = true; cascadeInsert = true; cascadeUpdate = true.

Field Detail
INLINE_INNER
final public static String INLINE_INNER(Code)



INLINE_OUTER
final public static String INLINE_OUTER(Code)



INNER_JOIN_MODE
final public static InlineMode INNER_JOIN_MODE(Code)
Inner (or equi-) join mode:



MANY_TO_MANY
final public static RelationshipType MANY_TO_MANY(Code)



MANY_TO_ONE
final public static RelationshipType MANY_TO_ONE(Code)



ONE_TO_MANY
final public static RelationshipType ONE_TO_MANY(Code)



ONE_TO_ONE
final public static RelationshipType ONE_TO_ONE(Code)



OUTER_JOIN_MODE
final public static InlineMode OUTER_JOIN_MODE(Code)
Outer (left outer) join mode



SEP
final public static String SEP(Code)



TAG_QUERY
final public static String TAG_QUERY(Code)



TAG_QUERY_CLASS
final public static String TAG_QUERY_CLASS(Code)



inlineMode
protected transient InlineMode inlineMode(Code)



parentIndeces
protected transient int[] parentIndeces(Code)



serialVersionUID
final static long serialVersionUID(Code)



thisIndeces
protected transient int[] thisIndeces(Code)




Constructor Detail
Link
public Link()(Code)



Link
public Link(Map map)(Code)



Link
public Link(String name)(Code)



Link
public Link(String name, Object result)(Code)



Link
public Link(String name, Object result, boolean adHoc)(Code)



Link
public Link(Query query, int[] parentIndeces, int thisIndeces)(Code)

Parameters:
  query - Query object
Parameters:
  parentIndeces - parent indeces which values are mapped to corresponding "this indeces"
Parameters:
  thisIndeces - "this indeces" indeces which values are mapped to corresponding parent ones



Link
public Link(Query query, int[] parentIndeces, int thisIndeces, String name)(Code)

Parameters:
  query - Query object
Parameters:
  parentIndeces - parent indeces which values are mapped to corresponding "this indeces"
Parameters:
  thisIndeces - "this indeces" indeces of this link query's SingularResultFactorywhich values are mapped to corresponding parent ones
Parameters:
  name - link name - mandatory for PersistentObject trees



Link
public Link(Link source)(Code)




Method Detail
addNotNullToResultCollection
public void addNotNullToResultCollection(Object value)(Code)



addParentPath
public void addParentPath(List parentPath)(Code)
Appends all of the elements in the specified parentPath to the end of this link's path
Parameters:
  parentPath - to append to the end ofthis link's path



addToPath
public void addToPath(String name)(Code)
Adds name to this link's path
Parameters:
  name - to add



addToResultCollection
public void addToResultCollection(Object value)(Code)



clone
public Object clone() throws CloneNotSupportedException(Code)
Returns Deep copy of this link Deep copy of this link
throws:
  CloneNotSupportedException -



cloneList
List cloneList(List list)(Code)



copyAll
public Link copyAll(Link source)(Code)



copyResults
public void copyResults(Link from)(Code)
Copies results from "from" link to this one including children
Parameters:
  from -



copyResults
public static void copyResults(Link from, Link to, int level)(Code)



copyResultsOneLevel
public void copyResultsOneLevel(Link from)(Code)
Copies results from "from" link to this one without touching children
Parameters:
  from -



fromMap
public void fromMap(Map map)(Code)



fromMapToIntArray
protected int[] fromMapToIntArray(PropertyMap map, String tag)(Code)



getDependencyIndex
public int getDependencyIndex()(Code)
Returns link dependency index link dependency index



getInlineMode
public InlineMode getInlineMode()(Code)
Experimental



getLifeCycleController
public LifeCycleController getLifeCycleController()(Code)
Returns LifeCycleController set for this link LifeCycleController set for this link



getName
public String getName()(Code)
Returns link name link name



getParentIndeces
public int[] getParentIndeces()(Code)
Returns parent indeces - indeces of the parent persistent object which contains a link [pointing to itself. Usually they are the primary key ones. parent indeces - indeces of the parent persistent object which contains a link [pointing to itself.Usually they are the primary key ones.



getPath
public List getPath()(Code)
Returns full path to this link built of the names of the parent chain full path to this link built of the names of the parent chain



getPathString
public String getPathString()(Code)
Returns full path to this link built of the names of the parent chain full path to this link built of the names of the parent chain



getQuery
public Query getQuery()(Code)
Returns query that is used to retrieve object trees query that is used to retrieve object trees



getResult
public Object getResult()(Code)
Returns result - data that is set during query execution for selects or by using setter methods for update operations result - data that is set during query execution for selectsor by using setter methods for update operations



getResultAsCollection
public Collection getResultAsCollection()(Code)



getThisIndeces
public int[] getThisIndeces()(Code)
Returns "this indeces" - indeces of this link query's SingularResultFactory which values are mapped to corresponding parent ones. Usually they are foregn key ones "this indeces" - indeces of this link query's SingularResultFactorywhich values are mapped to corresponding parent ones



isAdHoc
public boolean isAdHoc()(Code)



isCascadeDelete
public boolean isCascadeDelete()(Code)
Returns true if delete is to be propagated to this link when the parent one gets deleted true if delete is to be propagated to this link when the parent one gets deleted



isCascadeInsert
public boolean isCascadeInsert()(Code)
Returns true if delete is to be propagated to this link when the parent one gets inserted true if delete is to be propagated to this link when the parent one gets inserted



isCascadeUpdate
public boolean isCascadeUpdate()(Code)
Returns true if delete is to be propagated to this link when the parent one gets updated true if delete is to be propagated to this link when the parent one gets updated



isEndOfChain
public boolean isEndOfChain()(Code)
Returns true is this link is end of link chain. Marking link as end of chain prevents infinite loops of retrievals when circular link references are set. true is this link is end of link chain



isInline
public boolean isInline()(Code)
Experimental



isInner
public boolean isInner()(Code)



isInsertBeforeParent
public boolean isInsertBeforeParent()(Code)
Returns true if the result (data) of this link is to be inserted before the parent link's one true if the result (data) of this link is to be inserted before the parent link's one



isLazyRetrieval
public boolean isLazyRetrieval()(Code)
Returns true the result of this link has to be performed in "lazy" fashion true the result of this link has to be performed in "lazy" fashion



isOuter
public boolean isOuter()(Code)



isRetrieved
public boolean isRetrieved()(Code)



isTreatNullAsRemove
public boolean isTreatNullAsRemove()(Code)
Returns true if for one-to-one inversed relationship (this link contains foreign key object and its child contains the primary key ones) nullifying the foregn key field should cause deletion of the child object true if for one-to-one inversed relationship(this link contains foreign key object and its child contains the primary key ones)nullifying the foregn key field should cause deletion of the child object



newInstance
public Link newInstance()(Code)
Returns new instance of this link that inherits set of its parent properties new instance of this link that inherits set of its parent properties



newInstance0
protected Link newInstance0(Query query)(Code)



path2string
public static String path2string(List path)(Code)



populateClonedCollection
public void populateClonedCollection(Collection collection)(Code)



populateClonedMap
public void populateClonedMap(Map map)(Code)



setAdHoc
public void setAdHoc(boolean adHoc)(Code)



setCascadeAll
public Link setCascadeAll()(Code)
Sets cascadeDelete = true; cascadeInsert = true; cascadeUpdate = true. Values are used in PersistentObject trees itself



setCascadeDelete
public void setCascadeDelete(boolean cascadeDelete)(Code)
Sets true if delete is to be propagated to this link when the parent one gets deleted
Parameters:
  cascadeDelete - true if delete is to be propagated to this link when the parent one gets deleted



setCascadeInsert
public void setCascadeInsert(boolean cascadeInsert)(Code)
Sets true if delete is to be propagated to this link when the parent one gets inserted
Parameters:
  cascadeInsert - true if delete is to be propagated to this link when the parent one gets inserted



setCascadeUpdate
public void setCascadeUpdate(boolean cascadeUpdate)(Code)
Sets true if delete is to be propagated to this link when the parent one gets updated
Parameters:
  cascadeUpdate - true if delete is to be propagated to this link when the parent one gets updated



setDependencyIndex
public void setDependencyIndex(int dependencyIndex)(Code)
Sets link dependency index
Parameters:
  dependencyIndex - link dependency index



setEndOfChain
public void setEndOfChain(boolean endOfChain)(Code)
If true - this link is end of link chain. Marking link as end of chain prevents infinite loops of retrievals when circular link references are set.
Parameters:
  endOfChain - true is this link is end of link chain



setInlineMode
public void setInlineMode(InlineMode inlineMode)(Code)
Experimental



setInlineMode
public void setInlineMode(String childName, InlineMode inlineMode)(Code)



setInsertBeforeParent
public void setInsertBeforeParent(boolean insertBeforeParent)(Code)
Sets true if the result (data) of this link is to be inserted before the parent link's one
Parameters:
  insertBeforeParent - true if the result (data) of this link is to be inserted before the parent link's one



setLazyRetrieval
public void setLazyRetrieval(boolean lazyRetrieval)(Code)
Sets true the result of this link has to be performed in "lazy" fashion
Parameters:
  lazyRetrieval - true the result of this link has to be performed in "lazy" fashion



setLifeCycleController
public void setLifeCycleController(LifeCycleController lifeCycleController)(Code)
Sets LifeCycleController for this link
Parameters:
  lifeCycleController -



setName
public void setName(String name)(Code)
Sets link name. Link name is mandatory for PersistentObject trees
Parameters:
  name - link name



setParentIndeces
public void setParentIndeces(int[] parentIndeces)(Code)
Sets parent indeces - indeces of the parent persistent object which contains a link [pointing to itself. Usually they are the primary key ones.
Parameters:
  parentIndeces - indeces of the parent persistent object which contains a link [pointing to itself.Usually they are the primary key ones.



setPath
public void setPath(String pathString)(Code)



setPath
void setPath(List path)(Code)
Sets full path to this link built of the names of the parent chain
Parameters:
  path - full path to this link built of the names of the parent chain



setQuery
public void setQuery(Query query)(Code)
Sets query that is used to retrieve object trees
Parameters:
  query - query that is used to retrieve object trees



setRelationshipToParent
public void setRelationshipToParent(RelationshipType relationshipType)(Code)
Sets setRelationship to parent
Parameters:
  relationshipType -
See Also:   RelationshipType



setResult
public void setResult(Object result)(Code)
Sets result - data that is set during query execution for selects or by using setter methods for update operations
Parameters:
  result - data that is set during query execution for selectsor by using setter methods for update operations



setRetrieved
public void setRetrieved(boolean retrieved)(Code)



setThisIndeces
public void setThisIndeces(int[] thisIndeces)(Code)
Sets "this indeces" - indeces of this link query's SingularResultFactory which values are mapped to corresponding parent ones. Usually they are foregn key ones
Parameters:
  thisIndeces - "this indeces" - indeces of this link query's SingularResultFactorywhich values are mapped to corresponding parent ones



setTreatNullAsRemove
public void setTreatNullAsRemove(boolean treatNullAsRemove)(Code)
Sets true if for one-to-one inversed relationship (this link contains foreign key object and its child contains the primary key ones) nullifying the foregn key field should cause deletion of the child object
Parameters:
  treatNullAsRemove - true if for one-to-one inversed relationship(this link contains foreign key object and its child contains the primary key ones)nullifying the foregn key field should cause deletion of the child object



string2path
public static List string2path(String pathString)(Code)



toInlineMode
public static InlineMode toInlineMode(String modeName)(Code)



toLink
public Link toLink()(Code)
Returns itself itself



toMap
public Map toMap()(Code)



toMapArray
protected void toMapArray(Map map, String tag, int[] array)(Code)



toString
public String toString()(Code)



toSummaryString
public String toSummaryString()(Code)
Returns summary string summary string



unsetCascadeAll
public Link unsetCascadeAll()(Code)
Unsets cascadeDelete = true; cascadeInsert = true; cascadeUpdate = true. Values are used in PersistentObject trees itself



Fields inherited from com.completex.objective.components.persistency.ParentBase
final public static String ROOT(Code)(Java Doc)

Methods inherited from com.completex.objective.components.persistency.ParentBase
public void addChild(Link link)(Code)(Java Doc)
protected void addChild(String name, Link link)(Code)(Java Doc)
public static String buffer2string(StringBuffer buffer)(Code)(Java Doc)
public Link child(String name)(Code)(Java Doc)
public void clearNonInlinedChildren()(Code)(Java Doc)
protected LinkedHashMap cloneChildren() throws CloneNotSupportedException(Code)(Java Doc)
protected void fromMap(Map map)(Code)(Java Doc)
public Link getChild(String name)(Code)(Java Doc)
public Object getChildObject(String name)(Code)(Java Doc)
public LinkedHashMap getChildren()(Code)(Java Doc)
public static Link[] getInlineLinks(Parent parent)(Code)(Java Doc)
public static void getInlineLinks0(Parent parent, List inlineLinks)(Code)(Java Doc)
public Link getParentLink()(Code)(Java Doc)
public boolean hasChildren()(Code)(Java Doc)
public Link[] inlineLinks()(Code)(Java Doc)
public LinkIterator linkIterator()(Code)(Java Doc)
public LinkedHashMap newChildren(Link parent)(Code)(Java Doc)
public void setChildObject(String name, Object value)(Code)(Java Doc)
public void setChildren(LinkedHashMap children)(Code)(Java Doc)
public void setParentLink(Link parentLink)(Code)(Java Doc)
public Object toKey()(Code)(Java Doc)
abstract public Link toLink()(Code)(Java Doc)
protected Map toMap()(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.