View (Java™)
Represents a view or folder of a database and provides access to documents within it.
Syntax
public class View extends Base
Containment
Contained by: Database
Contains: Document, Datetime, ViewColumn, ViewEntry, ViewEntryCollection, ViewNavigator
Properties
Aliases through getAliases and setAliases
AllEntries through getAllEntries
BackgroundColor through getBackgroundColor and setBackgroundColor
ColumnCount through getColumnCount
ColumnNames through getColumnNames
Columns through getColumns
Created through getCreated
EntryCount through getEntryCount
HeaderLines through getHeaderLines
HttpURL through getHttpURL
IsAutoUpdate through isAutoUpdate and setAutoUpdate
IsCalendar through isCalendar
IsCategorized through isCategorized
IsConflict through isConflict
IsDefaultView through isDefaultView and setDefaultView
IsFolder through isFolder
IsHierarchical through isHierarchical
IsModified through isModified
IsPrivate through isPrivate
IsProhibitDesignRefresh through isProhibitDesignRefresh and setProhibitDesignRefresh
IsProtectReaders through isProtectReaders and setProtectReaders
LastModified through getLastModified
LockHolders through getLockHolders
Name through getName and setName
NotesURL through getNotesURL
Parent through getParent
Readers through getReaders and setReaders
RowLines through getRowLines
SelectionFormula through getSelectionFormula and setSelectionFormula
Spacing through getSpacing and setSpacing
TopLevelEntryCount through getTopLevelEntryCount
UniversalID through getUniversalID
ViewInheritedName through getViewInheritedName
Methods
getURL
recycle
toString
Access
You access a view or folder through the Database object that contains it. There are two ways:
- To access a view or folder when you know its name or alias, use getView.
- To access all the views and folders in a database, use getViews.
Returned is a View object or a vector of View objects that represent accessible views and/or folders in the database. These View objects may be public views or folders or private views or folders stored in the database that are owned by the effective id running the agent. Personal views and folders stored in the desktop cannot be accessed by programs.
To access a view or folder when you have a view entry, use getParent in ViewEntry.
Usage
A View object provides access to ViewEntry, ViewEntryCollection, and ViewNavigator objects:
- A ViewEntry object represents a row in the view and can be a document, category, or total. A document entry provides a handle to the associated Document object.
- A ViewEntryCollection object provides access to selected or all document ViewEntry objects. (Excluded are category and total ViewEntry objects.)
- A ViewNavigator object provides methods for navigating through selected or all ViewEntry and Document objects.
A View object provides access to ViewColumn objects, which contain information on each column in the view
If you create a View object then change a document so that it affects the underlying view, navigation with the View object may produce incorrect results.You must refresh the View object or create a new one. Document changes that affect views include additions, deletions, and changes to fields used by selection formulas. See refresh for further information.
Automatic updates: avoid
Avoid automatically updating the view by explicitly setting IsAutoUpdate to false especially if the view is a base for navigators or entry collections. Automatic updates degrade performance and may invalidate entries in child objects ("Entry not found in index"). You can update the view as needed with refresh.