|
jacquard 1.12.0 by The Web Engineering Factory and Toolworks | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectuk.co.weft.htform.Auxiliary
Auxiliary table information in a Form. An auxilliary shows data from records in related tables at the 'downhill' end of one-to-many links. If not told otherwise, Auxiliary expects that primary keys will have the same name as the table they are in and that foreign keys have the same name as the table they are keys for. It also assumes that the table will have a field called 'Description' containing a string description of the record.
| Field Summary | |
java.lang.String |
actionLabel
The text the user sees on the action link |
protected java.lang.String |
addLinkText
the caption to use as the link text for the add link |
boolean |
canAdd
true if users can add new records of this type |
protected java.lang.String |
childKey
the name of the primary key field in that table |
protected java.lang.String |
description
the name of the field in that table that contains user-readable identifying information |
protected java.lang.String |
parent
the name of the foreign key field within the table which relates to my parent record |
protected java.lang.String |
parentKey
the name of the variable in my context which holds the key of the parent record |
protected java.lang.String |
query
the query to prepare. |
protected java.lang.String |
table
the name of the table which I watch |
| Constructor Summary | |
Auxiliary(java.lang.String tableName,
java.lang.String parentName)
At minimum I must know my table and my parent. |
|
Auxiliary(java.lang.String tableName,
java.lang.String keyField,
java.lang.String parentName,
java.lang.String actionURL)
The action URL is a URL which points to a form allowing a single row from the auxiliary information to be edited. |
|
Auxiliary(java.lang.String tableName,
java.lang.String keyField,
java.lang.String parentName,
java.lang.String actionURL,
java.lang.String secTitle)
The section title is a user-friendly title to show above the auxilliary table |
|
Auxiliary(java.lang.String tableName,
java.lang.String keyField,
java.lang.String parentName,
java.lang.String parentId,
java.lang.String actionURL,
java.lang.String secTitle,
java.lang.String descField)
Specify everything needed to create a navigable auxiliary |
|
Auxiliary(java.lang.String tableName,
java.lang.String keyField,
java.lang.String parentName,
java.lang.String parentId,
java.lang.String actionURL,
java.lang.String secTitle,
java.lang.String descField,
java.lang.String addLinkText)
Specify everything needed to create a navigable auxiliary |
|
| Method Summary | |
protected void |
doInternalLayout(Context context,
javax.servlet.ServletOutputStream out,
java.lang.Integer parId,
java.lang.String parStr,
java.sql.Connection c)
Lay me out on the output stream of the current context. |
Node |
generate(Document doc,
Context context)
generate a DOM Node representing this Auxiliary. |
java.lang.String |
getAddLinkText()
|
java.lang.String |
getInternalTarget()
|
java.lang.String |
getShouldLayoutMagicToken()
|
java.lang.String |
getTitle()
|
protected void |
layout(Context context)
check whether I should be laid out in the current context and if so call doInternalLayout to do the actual layout |
protected void |
layoutCanAdd(Context context,
java.lang.String parStr)
Lay out my 'can add' link. |
void |
setAddLinkText(java.lang.String addLinkText)
|
boolean |
shouldLayout(Context context)
should we lay out this auxiliary in this context? |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public java.lang.String actionLabel
public boolean canAdd
protected java.lang.String addLinkText
protected java.lang.String childKey
protected java.lang.String description
protected java.lang.String parent
protected java.lang.String parentKey
protected java.lang.String query
protected java.lang.String table
| Constructor Detail |
public Auxiliary(java.lang.String tableName,
java.lang.String parentName)
tableName - the table this auxilliary displaysparentName - the name of the field in that table which is a
foreign key onto the table which the containing form edits
public Auxiliary(java.lang.String tableName,
java.lang.String keyField,
java.lang.String parentName,
java.lang.String actionURL)
tableName - the table this auxilliary displaysparentName - the name of the field in that table which is a
foreign key onto the table which the containing form editsactionURL - the URL to follow when a row is selected;keyField - the column in the table which contains the value to be
appended to the URL
public Auxiliary(java.lang.String tableName,
java.lang.String keyField,
java.lang.String parentName,
java.lang.String actionURL,
java.lang.String secTitle)
tableName - the table this auxilliary displaysparentName - the name of the field in that table which is a
foreign key onto the table which the containing form editsactionURL - the URL to follow when a row is selected;keyField - the column in the table which contains the value to be
appended to the URLsecTitle - the title (headline) for this auxiliary
public Auxiliary(java.lang.String tableName,
java.lang.String keyField,
java.lang.String parentName,
java.lang.String parentId,
java.lang.String actionURL,
java.lang.String secTitle,
java.lang.String descField)
tableName - the name of the auxiliary tablekeyField - the name of the primary key field in the auxiliary
tableparentName - the name of the field in the auxiliary table which is
foreign key onto the parent tableparentId - the name in the passed context which holds the value
the foreign key should matchactionURL - the URL to call when an item in the auxiliary is
clickedsecTitle - the title of this auxiliarydescField - the field which contains user-friendly identifying
information in the auxiliary table
public Auxiliary(java.lang.String tableName,
java.lang.String keyField,
java.lang.String parentName,
java.lang.String parentId,
java.lang.String actionURL,
java.lang.String secTitle,
java.lang.String descField,
java.lang.String addLinkText)
tableName - the name of the auxiliary tablekeyField - the name of the primary key field in the auxiliary
tableparentName - the name of the field in the auxiliary table which is
foreign key onto the parent tableparentId - the name in the passed context which holds the value
the foreign key should matchactionURL - the URL to call when an item in the auxiliary is
clickedsecTitle - the title of this auxiliarydescField - the field which contains user-friendly identifying
information in the auxiliary tableaddLinkText - the text to use for the add link| Method Detail |
public java.lang.String getInternalTarget()
public java.lang.String getShouldLayoutMagicToken()
public java.lang.String getTitle()
public Node generate(Document doc,
Context context)
throws java.lang.Exception
doc - the document in which this auxilliary livescontext - the context in which this auxiliary is to be created
java.lang.Exceptionpublic boolean shouldLayout(Context context)
context - the context
protected void doInternalLayout(Context context,
javax.servlet.ServletOutputStream out,
java.lang.Integer parId,
java.lang.String parStr,
java.sql.Connection c)
throws java.lang.Exception
context - the contextout - the output stream implied by the contextparId - the parent key field value as an integerparStr - the parent key field value as a stringc - a database connection
javax.servlet.ServletException - unlikely
java.io.IOException - if can't write to output stream
DataStoreException - unlikely
java.sql.SQLException - if database throws an error.
java.lang.Exception
protected void layout(Context context)
throws javax.servlet.ServletException,
java.io.IOException,
DataStoreException
context - the context.
javax.servlet.ServletException
java.io.IOException
DataStoreException
protected void layoutCanAdd(Context context,
java.lang.String parStr)
throws java.lang.Exception
context - the contextparStr - the parent key field value as a string
java.io.IOException - if can't write to output stream
java.lang.Exceptionpublic java.lang.String getAddLinkText()
public void setAddLinkText(java.lang.String addLinkText)
addLinkText - the addLinkText to set
|
jacquard 1.12.0 by The Web Engineering Factory and Toolworks | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||