From VisualWorks®, 7.6 of February 1, 2008 on February 1, 2008 at 12:49:49 pm (Dialog confirm: 'You are filing-in a Parcel source file!\\While this is possible it will not have\the same effect as loading the parcel.\None of the Parcel''s prerequisites will\be loaded and none of its load actions\will be performed.\\Are you sure you want to file-in?' withCRs) ifFalse: [self error: 'Parcel file-in abandoned. Choose terminate or close.'] <class> <name>BookLoanExample</name> <environment>Examples</environment> <super>Core.Object</super> <private>false</private> none borrower datedue book returned <imports></imports> <category>Examples-Help</category> <attributes> <package>Lens-Example</package> </attributes> </class> <comment> Examples.BookLoanExample
This example class is used to represent transactions involving the lending of a library book, for the Database1Example.
</comment> <class> <name>BorrowerExample</name> <environment>Examples</environment> <super>Core.Object</super> <private>false</private> none librarycard name address <imports></imports> <category>Examples-Help</category> <attributes> <package>Lens-Example</package> </attributes> </class> <comment> Examples.BorrowerExample
This example class is used to represent library customers (borrowers of books), for the Database1Example.
</comment> <class> <name>Database1Example</name> <environment>Examples</environment> <super>Lens.LensMainApplication</super> <private>false</private> none borrowerMgr borrower bookMgr bookLoanMgr <imports></imports> <category>Examples-Help</category> <attributes> <package>Lens-Example</package> </attributes> </class> <comment> Examples.Database1Example
This example class demonstrates various techniques involving programmatic use of an ObjectLens session, as well as advanced techniques involving a generated interface. To create sample tables for this example evaluate the class method #addSampleData. To later remove these tables evaluate class method #removeSampleData.
</comment> <class> <name>BookLoanMgrExample</name> <environment>Examples</environment> <super>Lens.LensDataManager</super> <private>false</private> none <imports></imports> <category>Examples-Help</category> <attributes> <package>Lens-Example</package> </attributes> </class> <comment> Examples.BookLoanMgrExample
This example class is the application model for a data form that is used by the Database1Example.
</comment> <class> <name>AdminExample</name> <environment>Examples</environment> <super>Core.Object</super> <private>false</private> none tablename nextnumber <imports></imports> <category>Examples-Help</category> <attributes> <package>Lens-Example</package> </attributes> </class> <comment> Examples.AdminExample
This example class is used to provide sequence numbers for the Database1Example
</comment> <class> <name>BookMgrExample</name> <environment>Examples</environment> <super>Lens.LensDataManager</super> <private>false</private> none <imports></imports> <category>Examples-Help</category> <attributes> <package>Lens-Example</package> </attributes> </class> <comment> Examples.BookMgrExample
This example class is the application model for a data form that is used by the Database1Example.
</comment> <class> <name>BorrowerMgrExample</name> <environment>Examples</environment> <super>Lens.LensDataManager</super> <private>false</private> none <imports></imports> <category>Examples-Help</category> <attributes> <package>Lens-Example</package> </attributes> </class> <comment> Examples.BorrowerMgrExample
This example class is the application model for a data form that is used by the Database1Example.
</comment> <class> <name>BookExample</name> <environment>Examples</environment> <super>Core.Object</super> <private>false</private> none bookid title author <imports></imports> <category>Examples-Help</category> <attributes> <package>Lens-Example</package> </attributes> </class> <comment> Examples.BookExample
This example class is used as a data class representing library books, for the Database1Example.
</comment> <methods> Examples.BookLoanExample <category>accessing</category>
book "Answer the receiver's book." ^book
book: newBook "Set the receiver's book to newBook." self update: 'book' to: newBook
borrower "Answer the receiver's borrower." ^borrower
borrower: newBorrower "Set the receiver's borrower to newBorrower." self update: 'borrower' to: newBorrower
datedue "Answer the receiver's datedue." ^datedue
datedue: newDatedue "Set the receiver's datedue to newDatedue." self update: 'datedue' to: newDatedue
returned "Answer the receiver's returned." ^returned
returned: newReturned "Set the receiver's returned to newReturned." self update: 'returned' to: newReturned
</methods> <methods> Examples.BorrowerExample <category>accessing</category>
address "Answer the receiver's address." ^address
address: newAddress "Set the receiver's address to newAddress." self update: 'address' to: newAddress
librarycard "Answer the receiver's librarycard." ^librarycard
librarycard: newLibrarycard "Set the receiver's librarycard to newLibrarycard." self update: 'librarycard' to: newLibrarycard
name "Answer the receiver's name." ^name
name: newName "Set the receiver's name to newName." self update: 'name' to: newName
</methods> <methods> Examples.BorrowerExample <category>initialize-release</category>
initialize librarycard := 0. name := ''. address := ''.
</methods> <methods> Examples.BorrowerExample class <category>instance creation</category>
new ^super new initialize.
</methods> <methods> Examples.Database1Example <category>private</category>
autoFetchFor: aChild "This method was generated by UIDefiner. Any edits made here will be lost whenever methods are automatically defined." aChild == self borrowerMgr ifTrue: [self borrowerMgrExampleFetch]. aChild == self bookMgr ifTrue: [self bookMgrExampleFetch].
fetchFor: aChild "This method was generated by UIDefiner. Any edits made here will be lost whenever methods are automatically defined." aChild == self borrowerMgr ifTrue: [self borrowerMgrExampleFetch]. aChild == self bookLoanMgr ifTrue: [self bookLoanMgrExampleFetch]. aChild == self bookMgr ifTrue: [self bookMgrExampleFetch].
removeChild: aChild "This method was generated by UIDefiner. Any edits made here will be lost whenever methods are automatically defined." super removeChild: aChild. aChild == borrowerMgr ifTrue: [borrowerMgr := nil]. aChild == bookLoanMgr ifTrue: [bookLoanMgr := nil]. aChild == bookMgr ifTrue: [bookMgr := nil]
resetAdminTable "Create and initialize the table that is used to hold the next library card number in sequence. This table is only needed in Ctlib, because Oracle provides its own serial number generation facility. Return true if successful, false otherwise." "Only needed for Ctlib." self session dataModel selector == #ctlibDMSpec ifFalse: [^true]. "If the table does not exist, create it."
</methods> <methods> Examples.Database1Example <category>accessing</category>
bookLoanMgr "This method was generated by UIDefiner. Any edits made here may be lost whenever methods are automatically defined. The initialization provided below may have been preempted by an initialize method." ^bookLoanMgr isNil ifTrue: [bookLoanMgr := BookLoanMgrExample new] ifFalse: [bookLoanMgr]
bookMgr "This method was generated by UIDefiner. Any edits made here may be lost whenever methods are automatically defined. The initialization provided below may have been preempted by an initialize method." ^bookMgr isNil ifTrue: [bookMgr := BookMgrExample new] ifFalse: [bookMgr]
borrowerMgr "This method was generated by UIDefiner. Any edits made here may be lost whenever methods are automatically defined. The initialization provided below may have been preempted by an initialize method." ^borrowerMgr isNil ifTrue: [borrowerMgr := BorrowerMgrExample new] ifFalse: [borrowerMgr]
</methods> <methods> Examples.Database1Example <category>actions</category>
bookLoanMgrExampleFetch "This method was generated by UIDefiner. Any edits made here may be lost whenever methods are automatically defined." bookLoanMgr isNil ifFalse: [bookLoanMgr rowsList: (Cursor database showWhile: [(self bookLoanMgr baseQuery session: self session) values])]
bookMgrExampleFetch "This method was generated by UIDefiner. Any edits made here may be lost whenever methods are automatically defined." bookMgr isNil ifFalse: [bookMgr rowsList: (Cursor database showWhile: [(self bookMgr baseQuery session: self session) values])]
bookMgrOpen "This method was generated by UIDefiner. Any edits made here may be lost whenever methods are automatically defined." self openChild: self bookMgr with: #windowSpec
borrowerMgrExampleFetch "This method was generated by UIDefiner. Any edits made here may be lost whenever methods are automatically defined." borrowerMgr isNil ifFalse: [borrowerMgr rowsList: (Cursor database showWhile: [(self borrowerMgr baseQuery session: self session) values])]
borrowerMgrOpen "This method was generated by UIDefiner. Any edits made here may be lost whenever methods are automatically defined." self openChild: self borrowerMgr with: #windowSpec
databaseLogin "In addition to the inherited action, equip the session with a block for generating serial numbers for the library card identifier." "Be sure to invoke the inherited method first." super databaseLogin. "Test to make sure the session was initialized successfully." session isNil ifTrue: [^session]. "Set the session's block for generating serial numbers." session serialNumberGeneratorBlock: [ :argsArray | | table adminQuery nextNum answerStream admin | "Get the tablename -- other args are not needed here." table := argsArray at: 3. "Get the query for finding the appropriate admin object." adminQuery := self adminForTable: table. "Perform the query and take the first returned object." adminQuery session: session. answerStream := adminQuery answer. answerStream atEnd "Get the next number, then increment the table's copy." ifFalse: [ admin := answerStream next. answerStream close. nextNum := admin nextnumber. admin nextnumber: nextNum + 1. admin postUpdates] "If no rows were returned, advise the user." ifTrue: [ nextNum := 0. Dialog warn: ' A sequence number for this borrower''s library card could not be generated. The Adminexample table needs a row with tablename =', table for: Dialog defaultParentWindow]. "The block returns the number to be assigned." nextNum]. ^session
lendBook: aBook "Create a book-loan transaction and ask the book loan manager to append a row for it." | loanTransaction | "If no borrower is selected, advise the user." self borrower value name isEmpty ifTrue: [^Dialog warn: 'Please select a borrower' for: self builder window]. loanTransaction := BookLoanExample new. loanTransaction borrower: self borrower value; book: aBook; datedue: (Timestamp fromDate: (Date today addDays: 14) andTime: Time now). self bookLoanMgr addTransaction: loanTransaction.
reportOverdueBooks "Forward this message to the book loan manager." ^self bookLoanMgr reportOverdueBooks.
</methods> <methods> Examples.Database1Example <category>aspects</category>
borrower ^borrower
borrower: newBorrower (newBorrower isKindOf: BorrowerExample) ifTrue: [self borrower value: newBorrower] ifFalse: [self borrower value: BorrowerExample new].
</methods> <methods> Examples.Database1Example <category>events</category>
changedBorrower "A new borrower has been selected -- update the table of loaned books." self borrower value == 0 ifTrue: [^nil]. self session isNil ifTrue: [^self]. self session isDisconnected ifFalse: [self bookLoanMgr performQuery]
</methods> <methods> Examples.Database1Example <category>initialize-release</category>
initialize super initialize. borrower := BorrowerExample new asValue. borrower onChangeSend: #changedBorrower to: self.
</methods> <methods> Examples.Database1Example class <category>data model accessing</category>
dataModelAt: aDesignator "Return a LensDataModel by choosing between the two known data models." "This is done this way since the dataModelDesignator method is removed when installing a data model on the class. This ignores the data model designator passed in as an argument, prompts for a user choice, and then lets the super implementation do the normal processing. This method is invoked as long as the dataModelDesignator method answers with an array that references an existing class. The inherited default implementation does so." | ldm | ldm:=super dataModelAt: aDesignator. (ldm databaseContext) environment: (UISettings preferenceFor: #dbDevEnvironment); username: (UISettings preferenceFor: #dbDevUsername). aDesignator last == #ctlibDMSpec ifTrue:[ | entry | entry:= Dialog request:'CTLib database name' initialAnswer: ldm databaseContext databaseName. entry isEmpty ifFalse:[ldm databaseContext databaseName: entry]]. ^ldm
</methods> <methods> Examples.Database1Example class <category>accessing</category>
dataModelDesignator "Give the user a choice between Oracle or CTLib." | dataModel | dataModel := Dialog choose: 'Which database?' labels: (Array with: 'Oracle' with: 'CTLib') values: #(#dataModelSpec #ctlibDMSpec) default: #dataModelSpec. ^Array with: #'Examples.Database1Example' with: dataModel.
lockPolicy ^#lockOnAccept
</methods> <methods> Examples.Database1Example class <category>data creation/removal</category>
addSampleData "This method creates sample database tables and loads data in those tables to support the VisualWorks Cookbook's Database chapter, for the Database1Example class. The following tables are created: AdminExample (for Sybase only) BookExample BorrowerExample BookLoanExample BorrowerExample$seq (for Oracle only) The companion method removeSampleData can be used to remove these sample tables. Only after the tables have been removed can this method safely be run again. If a table already exists, an error occurs. This method can be used for Sybase and Oracle database connections." | connection connectionClass session dialog builder accept driver username password environmnt envName | dialog := SimpleDialog new. builder := dialog builder. driver := #'Database.OracleConnection' asValue. username := (UISettings preferenceFor: #dbDevUsername) asValue. password := (UISettings preferenceFor: #dbDevPassword) asValue. environmnt := (UISettings preferenceFor: #dbDevEnvironment) asValue. "Prompt for choice of driver." builder aspectAt: #installedDBConnectsMenu put: AdHocQueryTool installedDBConnectsMenu. builder aspectAt: #whichDriverModel put: driver. builder aspectAt: #usernameModel put: username. builder aspectAt: #passwordModel put: password. builder aspectAt: #environmentModel put: environmnt. builder aspectAt: #accept put: [accept := true. dialog close]. builder aspectAt: #cancel put: [accept := false. dialog close]. dialog allButOpenFrom: (AdHocQueryTool interfaceSpecFor: #connectSpec). builder openDialog. accept ifFalse: [^Dialog warn: 'Sample tables were not created' for: Dialog defaultParentWindow]. driver := driver value. connectionClass := Smalltalk at: driver ifAbsent: [ ^Dialog warn: driver, ' is not present in the system.\Sample tables were not created.\Load driver then evaluate:\\' withCRs,self fullName,' ',thisContext selector asString for: Dialog defaultParentWindow]. "Register the environment for the logical environment used by the data model." envName := driver asString. envName := envName copyFrom: 1 to: (envName indexOfSubCollection: 'Connection' startingAt: 1) - 1. connectionClass addLogical: envName environment: environmnt value. "Create the connection." connection := connectionClass new. connection username: username value; password: password value; environment: environmnt value. connection connect. session := connection getSession. "Sybase" [driver asSymbol == #'Database.CTLibConnection' ifTrue: [ "dateFunction := 'getdate()'." session prepare: 'create table BookExample (bookid varchar(15) NOT NULL, title varchar(60) NULL, author varchar(30) NULL) create table BorrowerExample (librarycard int NOT NULL, name varchar(30) NULL, address varchar(60) NULL) create table BookLoanExample (borrower int NOT NULL, datedue smalldatetime NOT NULL, book varchar(15) NOT NULL, returned smalldatetime NULL) create table AdminExample (tablename varchar(20) NOT NULL, nextnumber int NULL)'; execute; answer; answer; answer; answer; answer. session prepare: 'execute sp_primarykey BookExample, bookid execute sp_primarykey BorrowerExample, librarycard execute sp_primarykey BookLoanExample, borrower, datedue, book execute sp_primarykey AdminExample, tablename'; execute; answer; answer; answer; answer; answer. session prepare: 'create unique clustered index iBookexample on BookExample (bookid) create unique clustered index iBorrowerexample on BorrowerExample(librarycard) create unique clustered index iBookloanexample on BookLoanExample (borrower, datedue, book) create unique clustered index iAdminexample on AdminExample (tablename)'; execute; answer; answer; answer; answer; answer. ]. "Oracle" driver asSymbol == #'Database.OracleConnection' ifTrue: [ "dateFunction := 'SYSDATE'." session prepare: 'create table BookExample (bookid varchar(15) NOT NULL, title varchar(60), author varchar(30), PRIMARY KEY (bookid))'; execute; answer. session prepare: 'create table BorrowerExample (librarycard number (12) NOT NULL, name varchar(30), address varchar(60), PRIMARY KEY (librarycard))'; execute; answer. session prepare: 'create table BookLoanExample (borrower number (12) NOT NULL, datedue date, book varchar(15), returned date)'; execute; answer. "Start at 4 to allow for the three borrowers we add." session prepare: 'create sequence BorrowerExample$seq start with 4'; execute; answer. session prepare: 'alter table BookLoanExample add primary key (borrower, datedue, book)'; execute; answer]. "Book data." session prepare: 'insert into BookExample values (''1-2345-678-9'', ''The Plague'', ''Albert Camus'')'; execute; answer. session prepare: 'insert into BookExample values (''2-3456-789-0'', ''Moby Dick'', ''Herman Melville'')'; execute; answer. session prepare: 'insert into BookExample values (''3-4567-890-1'', ''Crime and Punishment'', ''Fyodor Dostoyevsky'')'; execute; answer. "Borrower data." session prepare: 'insert into BorrowerExample values (1, ''Susan Chinn'', ''1199 Poplar Avenue, Ferndale, CA 95536'')'; execute; answer. session prepare: 'insert into BorrowerExample values (2, ''Arthur Mbuyo'', ''476 Redwood Drive, Ferndale, CA 95536'')'; execute; answer. session prepare: 'insert into BorrowerExample values (3, ''Alex Sanchez'', ''477 Oak St., Ferndale, CA 95536'')'; execute; answer. "Sybase admin and book-loan data." driver asSymbol == #'Database.CTLibConnection' ifTrue: [ session prepare: 'insert into AdminExample values (''BorrowerExample'', 4) insert into BookLoanExample values (1, dateadd(day, -18, getdate()), ''1-2345-678-9'', dateadd(day, -5, getdate())) insert into BookLoanExample values (1, dateadd(day, -18, getdate()), ''2-3456-789-0'', null) insert into BookLoanExample values (2, dateadd(day, -26, getdate()), ''2-3456-789-0'', null)'; execute; answer; answer; answer; answer]. "Oracle book-loan data." driver asSymbol == #'Database.OracleConnection' ifTrue: [ session prepare: 'insert into BookLoanExample values (1, SYSDATE -18, ''1-2345-678-9'', SYSDATE -5)'; execute; answer. session prepare: 'insert into BookLoanExample values (1, SYSDATE -18, ''2-3456-789-0'', NULL)'; execute; answer. session prepare: 'insert into BookLoanExample values (2, SYSDATE -26, ''2-3456-789-0'', NULL)'; execute; answer]. Dialog warn: 'Sample tables and data installed.'] ensure: [connection disconnect]
removeSampleData "This method deletes sample database tables that are used to support the VisualWorks Cookbook's Database chapter, for the Database1Example class. The following tables are dropped: BookLoanExample BookExample BorrowerExample BorrowerExample.seq (for Oracle only) AdminExample (for Sybase only) The companion method addSampleData can be used to add these sample tables. Only after the tables have been added can this script safely be run. If a table does not exist, an error occurs. This script can be used for Sybase and Oracle database connections." | connection connectionClass session dialog builder accept driver username password environmnt | dialog := SimpleDialog new. builder := dialog builder. driver := #'Database.OracleConnection' asValue. username := (UISettings preferenceFor: #dbDevUsername) asValue. password := (UISettings preferenceFor: #dbDevPassword) asValue. environmnt := (UISettings preferenceFor: #dbDevEnvironment) asValue. "Prompt for connection parameters." builder aspectAt: #installedDBConnectsMenu put: AdHocQueryTool installedDBConnectsMenu. builder aspectAt: #whichDriverModel put: driver. builder aspectAt: #usernameModel put: username. builder aspectAt: #passwordModel put: password. builder aspectAt: #environmentModel put: environmnt. builder aspectAt: #accept put: [accept := true. dialog close]. builder aspectAt: #cancel put: [accept := false. dialog close]. dialog allButOpenFrom: (AdHocQueryTool interfaceSpecFor: #connectSpec). builder openDialog. accept ifFalse: [^Dialog warn: 'Sample tables were not removed.' for: Dialog defaultParentWindow]. driver := driver value. connectionClass := Smalltalk at: driver ifAbsent: [^Dialog warn: driver, ' is not present in the system\Sample tables were not removed.\Load driver then evaluate:\\' withCRs,self fullName,' ',thisContext selector asString]. "Connect to the chosen database." connection := connectionClass new. connection username: username value; password: password value; environment: environmnt value. connection connect. "Drop the tables." [session := connection getSession. session prepare: 'drop table BookLoanExample'; execute; answer. session prepare: 'drop table BookExample'; execute; answer. session prepare: 'drop table BorrowerExample'; execute; answer. driver asSymbol == #'Database.CTLibConnection' ifTrue: [ session prepare: 'drop table AdminExample'; execute; answer]. driver asSymbol == #'Database.OracleConnection' ifTrue: [ session prepare: 'drop sequence BorrowerExample$seq'; execute; answer]. Dialog warn: 'Sample tables were removed.' for: Dialog defaultParentWindow] ensure: [connection disconnect]
</methods> <methods> Examples.BookLoanMgrExample <category>actions</category>
addTransaction: aBookLoan "Append the given book-loan transaction to the list." "Append the transaction." self newSession add: aBookLoan. "Re-fetch the displayed list." self performQuery.
reportOverdueBooks "Create and display a report of all overdue books. This method demonstrates how to execute a query and process the returned rows one by one." | query answerStream report nextRow name address title datedue penaltyPerDay daysOverdue fine fineString | "Initialize the report stream." report := String new writeStream. report nextPutAll: 'Overdue books as of ', Date today printString. report cr; cr. "Get the query." query := self overdueBooksQuery. "Give the query the current session." query session: self session. "Execute the query and get the answer stream." answerStream := query answer. "Process each row of the answer stream." [answerStream atEnd] whileFalse: [ nextRow := answerStream next. "Unload the row array into temporary variables." name := nextRow at: 1. address := nextRow at: 2. title := nextRow at: 3. datedue := nextRow at: 4. "Compute the overdue penalty based on the due date." penaltyPerDay := 0.10s. daysOverdue := Date today subtractDate: datedue asDate. fine := daysOverdue * penaltyPerDay. "Format the penalty amount as US dollars." fineString := PrintConverter print: fine formattedBy: '$###.##'. "Add an item to the report stream." report nextPutAll: title; cr; tab; nextPutAll: name; cr; tab; nextPutAll: address; cr; tab; print: daysOverdue; nextPutAll: ' days overdue, '; nextPutAll: fineString; nextPutAll: ' penalty'; cr; cr]. "Close the answer stream." answerStream close. "Display the report." report close. Dialog warn: report contents for: Dialog defaultParentWindow.
</methods> <methods> Examples.BookLoanMgrExample <category>events</category>
noticeOfCommit "This message is sent when the session's transaction is about to be committed. Here, we use it as an opportunity to prompt the user for permission to accept any pending edits so they will be included in the commit." | confirmed | self isEditing ifTrue: [ confirmed := Dialog confirm: 'Book-loan edits are in progress -- OK to Accept?' initialAnswer: true for: self builder window. confirmed ifTrue: [self accept]].
</methods> <methods> Examples.BookLoanMgrExample class <category>accessing</category>
dataModelDesignator ^#(#{Database1Example} #dataModelSpec)
rowType ^rowType isNil ifTrue: [rowType := #(#(#LensContainerReference #name: #bookloanexample #referred: #BookLoanExample) #(#LensContainerReference #name: #bookexample #referred: #BookExample)) collect: [:elt | UIDataReference decodeFromLiteralArray: elt]] ifFalse: [rowType]
</methods> <methods> Examples.AdminExample <category>accessing</category>
nextnumber "Answer the receiver's nextnumber." ^nextnumber
nextnumber: newNextnumber "Set the receiver's nextnumber to newNextnumber." self update: 'nextnumber' to: newNextnumber
tablename "Answer the receiver's tablename." ^tablename
tablename: newTablename "Set the receiver's tablename to newTablename." self update: 'tablename' to: newTablename
</methods> <methods> Examples.BookMgrExample <category>actions</category>
lendBook "Ask the parent application to lend the selected book to the current borrower." self parent lendBook: self row value.
</methods> <methods> Examples.BookMgrExample <category>private</category>
setEnablement "In addition to the inherited enabling actions, enable or disable the Lend button." super setEnablement. (self isEditing or: [self isCreating]) ifTrue: [self enable: false group: #(#lend )] ifFalse: [self enable: true group: #(#lend )].
</methods> <methods> Examples.BookMgrExample class <category>accessing</category>
dataModelDesignator ^#(#{Database1Example} #dataModelSpec)
rowType ^rowType isNil ifTrue: [rowType := #(#(#LensContainerReference #name: #bookexample #referred: #BookExample)) collect: [:elt | UIDataReference decodeFromLiteralArray: elt]] ifFalse: [rowType]
</methods> <methods> Examples.BorrowerMgrExample <category>private</category>
endCreating "In addition to the inherited actions, refresh the cell in the DatasetView that contains the newly generated (but not yet displayed) serial number." | datasetView rowNum colNum | "Be sure to invoke the inherited implementation first." super endCreating. "Get the dataset widget." datasetView := (self builder componentAt: #rows) widget. "Get the row and column of the new serial number. In this case, the serial number is the second column, because the first column is used for the row marker." colNum := 2. rowNum := self rows selectionIndex. "Refresh the cell in the widget." datasetView invalidateCellIndex: colNum @ rowNum. "Give the newly created borrower to the main window." self parent borrower: self row value.
</methods> <methods> Examples.BorrowerMgrExample <category>events</category>
selectionChanged "In addition to the inherited actions, give the newly selected borrower to the parent." super selectionChanged. self parent borrower: self row value.
</methods> <methods> Examples.BorrowerMgrExample class <category>accessing</category>
dataModelDesignator ^#(#{Database1Example} #dataModelSpec)
rowType ^rowType isNil ifTrue: [rowType := #(#(#LensContainerReference #name: #borrowerexample #referred: #BorrowerExample)) collect: [:elt | UIDataReference decodeFromLiteralArray: elt]] ifFalse: [rowType]
</methods> <methods> Examples.BookExample <category>accessing</category>
author "Answer the receiver's author." ^author
author: newAuthor "Set the receiver's author to newAuthor." self update: 'author' to: newAuthor
bookid "Answer the receiver's bookid." ^bookid
bookid: newBookid "Set the receiver's bookid to newBookid." self update: 'bookid' to: newBookid
title "Answer the receiver's title." ^title
title: newTitle "Set the receiver's title to newTitle." self update: 'title' to: newTitle
</methods> <methods> Examples.Database1Example <category>query</category>
adminForTable: tablename "QueryEditor new openOnClass: self andSelector: #adminForTable: tablename" <resource: #query> | _qo | _qo := LensQuery new. _qo description: 'adminForTable: tablename'. _qo arrayContainerNames: #((#adminexample #AdminExample) ). _qo answerBlockSource: ''. _qo selectWhere: [:adminexample | adminexample tablename = tablename ]. _qo selectBlockSource: 'adminexample tablename = tablename '. _qo orderByBlockSource: ''. _qo groupByBlockSource: ''. _qo locking. _qo mode: nil. ^_qo
</methods> <methods> Examples.Database1Example class <category>resources</category>
menuBar "UIMenuEditor new openOnClass: self andSelector: #menuBar" <resource: #menu> ^#(#Menu #( #(#MenuItem #label: 'Database' #submenu: #(#Menu #( #(#MenuItem #label: 'Login' ) #(#MenuItem #label: 'Commit' ) #(#MenuItem #label: 'Rollback' ) #(#MenuItem #label: 'Logout' ) #(#MenuItem #label: 'Exit' ) ) #(5 ) #(#databaseLogin #databaseCommit #databaseRollback #databaseLogout #closeRequest ) ) ) #(#MenuItem #label: 'Report' #submenu: #(#Menu #( #(#MenuItem #label: 'Overdue Books' ) ) #(1 ) #(#reportOverdueBooks ) ) ) ) #(2 ) #(nil nil ) ) decodeAsLiteralArray
</methods> <methods> Examples.Database1Example class <category>interface specs</category>
windowSpec "UIPainter new openOnClass: self andSelector: #windowSpec" <resource: #canvas> ^#(#FullSpec #window: #(#WindowSpec #label: 'Database1Example' #bounds: #(#Rectangle 403 399 872 713 ) #flags: 4 #menu: #menuBar ) #component: #(#SpecCollection #collection: #( #(#EmbeddedDetailSpec #layout: #(#LayoutFrame 10 0 120 0 -10 1 -10 1 ) #name: #bookLoanMgrExample #majorKey: #BookLoanMgrExample #minorKey: #windowSpec #clientKey: #bookLoanMgr #fetchAction: #bookLoanMgrExampleFetch #synchronize: false #autoFetch: false ) #(#LinkedDetailSpec #layout: #(#Rectangle 170 10 300 50 ) #name: 'bookMgr' #label: 'Find Book' #defaultable: true #clientKey: #bookMgr #majorKey: #BookMgrExample #minorKey: #windowSpec #openAction: #bookMgrOpen #fetchAction: #bookMgrExampleFetch #synchronize: false ) #(#LabelSpec #layout: #(#Point 10 70 ) #label: 'Borrower' ) #(#InputFieldSpec #layout: #(#LayoutFrame 110 0 70 0 -10 1 100 0 ) #name: #borrower #model: #'borrower name' ) #(#LinkedDetailSpec #layout: #(#Rectangle 10 10 160 50 ) #name: 'borrowerMgr' #label: 'Find Borrower' #defaultable: true #clientKey: #borrowerMgr #majorKey: #BorrowerMgrExample #minorKey: #windowSpec #openAction: #borrowerMgrOpen #fetchAction: #borrowerMgrExampleFetch #synchronize: false #autoOpen: false ) ) ) )
</methods> <methods> Examples.Database1Example class <category>lens data model specs</category>
ctlibDMSpec "LensEditor new openOnClass: self andSelector: #ctlibDMSpec" <resource: #dataModel> ^#(#LensDataModel #setDatabaseContext: #(#CTLibContext #username: '' #environment: '' #databaseName: '' ) #structureTypes: #( #(#LensStructureType #memberClass: #'Examples.BookExample' #setVariables: #( #(#LensStructureVariable #name: 'bookid' #setValueType: #String #fieldType: #String #column: #(#CTLibTableColumn #name: 'bookid' #dataType: 'varchar' #width: 15 #isNotNil: true ) #generatesAccessor: true #generatesMutator: true #isId: true #privateIsMapped: true #isNotNil: true ) #(#LensStructureVariable #name: 'title' #setValueType: #String #fieldType: #String #column: #(#CTLibTableColumn #name: 'title' #dataType: 'varchar' #width: 60 #isNotNil: false ) #generatesAccessor: true #generatesMutator: true #isId: false #privateIsMapped: true #isNotNil: false ) #(#LensStructureVariable #name: 'author' #setValueType: #String #fieldType: #String #column: #(#CTLibTableColumn #name: 'author' #dataType: 'varchar' #width: 30 #isNotNil: false ) #generatesAccessor: true #generatesMutator: true #isId: false #privateIsMapped: true #isNotNil: false ) ) #table: #(#CTLibTable #name: 'BookExample' ) #defersPostingUpdates: true #idVariable: #('bookid' ) #idGeneratorType: #userDefinedId #indexes: #() ) #(#LensStructureType #memberClass: #'Examples.BorrowerExample' #setVariables: #( #(#LensStructureVariable #name: 'librarycard' #setValueType: #SerialNumber #fieldType: #SerialNumber #column: #(#CTLibTableColumn #name: 'librarycard' #dataType: 'int' #scale: 0 #isNotNil: true ) #generatesAccessor: true #generatesMutator: true #isId: true #privateIsMapped: true #isNotNil: true ) #(#LensStructureVariable #name: 'name' #setValueType: #String #fieldType: #String #column: #(#CTLibTableColumn #name: 'name' #dataType: 'varchar' #width: 30 #isNotNil: false ) #generatesAccessor: true #generatesMutator: true #isId: false #privateIsMapped: true #isNotNil: false ) #(#LensStructureVariable #name: 'address' #setValueType: #String #fieldType: #String #column: #(#CTLibTableColumn #name: 'address' #dataType: 'varchar' #width: 60 #isNotNil: false ) #generatesAccessor: true #generatesMutator: true #isId: false #privateIsMapped: true #isNotNil: false ) ) #table: #(#CTLibTable #name: 'BorrowerExample' ) #defersPostingUpdates: true #idVariable: #('librarycard' ) #idGeneratorType: #userDefinedId #indexes: #() ) #(#LensStructureType #memberClass: #'Examples.BookLoanExample' #setVariables: #( #(#LensStructureVariable #name: 'borrower' #setValueType: #BorrowerExample #fieldType: #SerialNumber #column: #(#CTLibTableColumn #name: 'borrower' #dataType: 'int' #scale: 0 #isNotNil: true ) #generatesAccessor: true #generatesMutator: true #isId: true #privateIsMapped: true #isNotNil: true ) #(#LensStructureVariable #name: 'datedue' #setValueType: #Timestamp #fieldType: #Timestamp #column: #(#CTLibTableColumn #name: 'datedue' #dataType: 'smalldatetime' #scale: 3 #isNotNil: true ) #generatesAccessor: true #generatesMutator: true #isId: true #privateIsMapped: true #isNotNil: true ) #(#LensStructureVariable #name: 'book' #setValueType: #BookExample #fieldType: #String #column: #(#CTLibTableColumn #name: 'book' #dataType: 'varchar' #width: 15 #isNotNil: true ) #generatesAccessor: true #generatesMutator: true #isId: true #privateIsMapped: true #isNotNil: true ) #(#LensStructureVariable #name: 'returned' #setValueType: #Timestamp #fieldType: #Timestamp #column: #(#CTLibTableColumn #name: 'returned' #dataType: 'smalldatetime' #scale: 3 #isNotNil: false ) #generatesAccessor: true #generatesMutator: true #isId: false #privateIsMapped: true #isNotNil: false ) ) #table: #(#CTLibTable #name: 'BookLoanExample' ) #defersPostingUpdates: true #idVariable: #('borrower' 'datedue' 'book' ) #idGeneratorType: #userDefinedId #indexes: #() ) #(#LensStructureType #memberClass: #'Examples.AdminExample' #setVariables: #( #(#LensStructureVariable #name: 'tablename' #setValueType: #String #fieldType: #String #column: #(#CTLibTableColumn #name: 'tablename' #dataType: 'varchar' #width: 20 #isNotNil: true ) #generatesAccessor: true #generatesMutator: true #isId: true #privateIsMapped: true #isNotNil: true ) #(#LensStructureVariable #name: 'nextnumber' #setValueType: #Integer #fieldType: #Integer #column: #(#CTLibTableColumn #name: 'nextnumber' #dataType: 'int' #scale: 0 #isNotNil: false ) #generatesAccessor: true #generatesMutator: true #isId: false #privateIsMapped: true #isNotNil: false ) ) #table: #(#CTLibTable #name: 'Adminexample' ) #defersPostingUpdates: true #idVariable: #('tablename' ) #idGeneratorType: #userDefinedId #indexes: #() ) ) #lensPolicyName: #Mixed #validity: #installed )
dataModelSpec "LensEditor new openOnClass: self andSelector: #dataModelSpec" <resource: #dataModel> ^#(#LensDataModel #setDatabaseContext: #(#Oracle7Context #username: '' #environment: '' ) #structureTypes: #( #(#LensStructureType #memberClass: #'Examples.BookExample' #setVariables: #( #(#LensStructureVariable #name: 'bookid' #setValueType: #String #fieldType: #String #column: #(#Oracle7TableColumn #name: 'BOOKID' #dataType: 'varchar2' #maxColumnConstraint: 15 #isNotNil: true ) #generatesAccessor: true #generatesMutator: true #isId: true #privateIsMapped: true #isNotNil: true ) #(#LensStructureVariable #name: 'title' #setValueType: #String #fieldType: #String #column: #(#Oracle7TableColumn #name: 'TITLE' #dataType: 'varchar2' #maxColumnConstraint: 60 ) #generatesAccessor: true #generatesMutator: true #privateIsMapped: true ) #(#LensStructureVariable #name: 'author' #setValueType: #String #fieldType: #String #column: #(#Oracle7TableColumn #name: 'AUTHOR' #dataType: 'varchar2' #maxColumnConstraint: 30 ) #generatesAccessor: true #generatesMutator: true #privateIsMapped: true ) ) #table: #(#Oracle7Table #name: 'BOOKEXAMPLE' ) #defersPostingUpdates: true #idVariable: #('bookid' ) #idGeneratorType: #userDefinedId #indexes: #() ) #(#LensStructureType #memberClass: #'Examples.BorrowerExample' #setVariables: #( #(#LensStructureVariable #name: 'librarycard' #setValueType: #SerialNumber #fieldType: #SerialNumber #column: #(#Oracle7TableColumn #name: 'LIBRARYCARD' #dataType: 'number' #precision: 12 #scale: 0 #isNotNil: true ) #generatesAccessor: true #generatesMutator: true #isId: true #privateIsMapped: true #isNotNil: true ) #(#LensStructureVariable #name: 'name' #setValueType: #String #fieldType: #String #column: #(#Oracle7TableColumn #name: 'NAME' #dataType: 'varchar2' #maxColumnConstraint: 30 ) #generatesAccessor: true #generatesMutator: true #privateIsMapped: true ) #(#LensStructureVariable #name: 'address' #setValueType: #String #fieldType: #String #column: #(#Oracle7TableColumn #name: 'ADDRESS' #dataType: 'varchar2' #maxColumnConstraint: 60 ) #generatesAccessor: true #generatesMutator: true #privateIsMapped: true ) ) #table: #(#Oracle7Table #name: 'BORROWEREXAMPLE' ) #defersPostingUpdates: true #idVariable: #('librarycard' ) #idGeneratorType: #userDefinedId #indexes: #() ) #(#LensStructureType #memberClass: #'Examples.BookLoanExample' #setVariables: #( #(#LensStructureVariable #name: 'borrower' #setValueType: #BorrowerExample #fieldType: #SerialNumber #column: #(#Oracle7TableColumn #name: 'BORROWER' #dataType: 'number' #precision: 12 #scale: 0 #isNotNil: true ) #generatesAccessor: true #generatesMutator: true #isId: true #privateIsMapped: true #isNotNil: true ) #(#LensStructureVariable #name: 'datedue' #setValueType: #Timestamp #fieldType: #Timestamp #column: #(#Oracle7TableColumn #name: 'DATEDUE' #dataType: 'date' #isNotNil: true ) #generatesAccessor: true #generatesMutator: true #isId: true #privateIsMapped: true #isNotNil: true ) #(#LensStructureVariable #name: 'book' #setValueType: #BookExample #fieldType: #String #column: #(#Oracle7TableColumn #name: 'BOOK' #dataType: 'varchar2' #maxColumnConstraint: 15 #isNotNil: true ) #generatesAccessor: true #generatesMutator: true #isId: true #privateIsMapped: true #isNotNil: true ) #(#LensStructureVariable #name: 'returned' #setValueType: #Timestamp #fieldType: #Timestamp #column: #(#Oracle7TableColumn #name: 'RETURNED' #dataType: 'date' ) #generatesAccessor: true #generatesMutator: true #privateIsMapped: true ) ) #table: #(#Oracle7Table #name: 'BOOKLOANEXAMPLE' ) #defersPostingUpdates: true #idVariable: #('borrower' 'datedue' 'book' ) #idGeneratorType: #userDefinedId #indexes: #() ) ) #lensPolicyName: #Mixed #lensTransactionPolicyName: #PessimisticRR #validity: #installed )
</methods> <methods> Examples.BookLoanMgrExample <category>query</category>
overdueBooksQuery "QueryEditor new openOnClass: self andSelector: #overdueBooksQuery" <resource: #query> | _qo | _qo := LensQuery new. _qo description: 'overdueBooksQuery'. _qo arrayContainerNames: #((#bookloanexample #BookLoanExample) ). _qo answer: [:bookloanexample | bookloanexample borrower name, bookloanexample borrower address, bookloanexample book title, bookloanexample datedue]. _qo answerBlockSource: 'bookloanexample borrower name, bookloanexample borrower address, bookloanexample book title, bookloanexample datedue'. _qo selectWhere: [:bookloanexample | (bookloanexample datedue < Timestamp now) & (bookloanexample returned isNil)]. _qo selectBlockSource: '(bookloanexample datedue < Timestamp now) & (bookloanexample returned isNil)'. _qo orderByBlockSource: ''. _qo groupByBlockSource: ''. _qo mode: nil. ^_qo
ownQuery "QueryEditor new openOnClass: self andSelector: #ownQuery" <resource: #query> | _qo | _qo := LensQuery new. _qo description: 'ownQuery'. _qo arrayContainerNames: #((#bookloanexample #BookLoanExample) (#bookexample #BookExample) ). _qo answerBlockSource: ''. _qo selectWhere: [:bookloanexample :bookexample | (bookloanexample book = bookexample) & (bookloanexample borrower librarycard = self parent borrower value librarycard) ]. _qo selectBlockSource: '(bookloanexample book = bookexample) & (bookloanexample borrower librarycard = self parent borrower value librarycard) '. _qo orderByBlockSource: ''. _qo groupByBlockSource: ''. _qo mode: #own. ^_qo
</methods> <methods> Examples.BookLoanMgrExample class <category>interface specs</category>
windowSpec "UIPainter new openOnClass: self andSelector: #windowSpec" <resource: #canvas> ^#(#FullSpec #window: #(#WindowSpec #label: 'BookLoanMgrExample' #bounds: #(#Rectangle 16 443 483 650 ) ) #component: #(#SpecCollection #collection: #( #(#DataSetSpec #layout: #(#LayoutFrame 0 0 43 0 0 1.0 -1 1 ) #name: #rows #model: #rows #callbacksSpec: #(#UIEventCallbackSubSpec #requestValueChangeSelector: #rowChangeRequest ) #columns: #( #(#DataSetColumnSpec #labelIsImage: false #width: 30 #rendererType: #rowSelector #editorType: #rowSelector #noScroll: false ) #(#DataSetColumnSpec #model: #'row @ bookloanexample datedue | trigger' #callbacksSpec: #(#UIEventCallbackSubSpec #valueChangeSelector: #valueChanged #requestFocusInSelector: #focusInRequest ) #label: 'Date Due' #labelIsImage: false #width: 100 #rendererType: #Text #editorType: #InputField #font: #system #alignment: #left #type: #timestamp #noScroll: true #formatString: 'm/d/yy h:mm AM/PM' ) #(#DataSetColumnSpec #model: #'row @ bookloanexample returned | trigger' #callbacksSpec: #(#UIEventCallbackSubSpec #valueChangeSelector: #valueChanged #requestFocusInSelector: #focusInRequest ) #label: 'Returned' #labelIsImage: false #width: 100 #rendererType: #Text #editorType: #InputField #font: #system #alignment: #left #type: #timestamp #noScroll: true #formatString: 'm/d/yy h:mm AM/PM' ) #(#DataSetColumnSpec #model: #'row @ bookexample title | trigger' #callbacksSpec: #(#UIEventCallbackSubSpec #valueChangeSelector: #valueChanged #requestFocusInSelector: #focusInRequest ) #label: 'Title' #labelIsImage: false #width: 400 #rendererType: #Text #editorType: #None #font: #system #alignment: #left #type: #string #noScroll: false ) ) ) #(#ActionButtonSpec #layout: #(#Rectangle 82 6 147 31 ) #name: #cancel #flags: 40 #isOpaque: true #model: #cancel #label: 'Cancel' #isDefault: false ) #(#ActionButtonSpec #layout: #(#Rectangle 17 6 82 31 ) #name: #accept #flags: 40 #isOpaque: true #model: #accept #label: 'Accept' #isDefault: false ) ) ) )
</methods> <methods> Examples.BookMgrExample <category>query</category>
ownQuery "This method was generated by UIDefiner. Any edits made here will be lost if the class is regenerated anew." "QueryEditor new openOnClass: self andSelector: #ownQuery" <resource: #query> | _qo | _qo := LensQuery new. _qo description: 'ownQuery'. _qo arrayContainerNames: #((#bookexample #BookExample) ). _qo mode: #own. ^_qo
</methods> <methods> Examples.BookMgrExample class <category>interface specs</category>
windowSpec "UIPainter new openOnClass: self andSelector: #windowSpec" <resource: #canvas> ^#(#FullSpec #window: #(#WindowSpec #label: 'BookMgrExample' #bounds: #(#Rectangle 265 416 734 624 ) ) #component: #(#SpecCollection #collection: #( #(#DataSetSpec #layout: #(#LayoutFrame 0 0 43 0 0 1.0 -1 1 ) #model: #rows #callbacksSpec: #(#UIEventCallbackSubSpec #requestValueChangeSelector: #rowChangeRequest ) #columns: #( #(#DataSetColumnSpec #labelIsImage: false #width: 30 #rendererType: #rowSelector #editorType: #rowSelector #noScroll: false ) #(#DataSetColumnSpec #model: #'row @ bookexample bookid | trigger' #callbacksSpec: #(#UIEventCallbackSubSpec #valueChangeSelector: #valueChanged #requestFocusInSelector: #focusInRequest ) #label: 'Book ID' #labelIsImage: false #width: 160 #rendererType: #Text #editorType: #InputField #size: 15 #font: #system #alignment: #left #type: #string #noScroll: false ) #(#DataSetColumnSpec #model: #'row @ bookexample title | trigger' #callbacksSpec: #(#UIEventCallbackSubSpec #valueChangeSelector: #valueChanged #requestFocusInSelector: #focusInRequest ) #label: 'Title' #labelIsImage: false #width: 400 #rendererType: #Text #editorType: #InputField #size: 60 #font: #system #alignment: #left #type: #string #noScroll: false ) #(#DataSetColumnSpec #model: #'row @ bookexample author | trigger' #callbacksSpec: #(#UIEventCallbackSubSpec #valueChangeSelector: #valueChanged #requestFocusInSelector: #focusInRequest ) #label: 'Author' #labelIsImage: false #width: 300 #rendererType: #Text #editorType: #InputField #size: 30 #font: #system #alignment: #left #type: #string #noScroll: false ) ) ) #(#ActionButtonSpec #layout: #(#Rectangle 11 6 71 31 ) #name: #lend #model: #lendBook #label: 'Lend' #isDefault: true #defaultable: true ) #(#ActionButtonSpec #layout: #(#Rectangle 81 6 146 31 ) #name: #addRow #isOpaque: true #model: #addRow #label: 'New' #isDefault: false ) #(#ActionButtonSpec #layout: #(#Rectangle 146 6 211 31 ) #name: #removeRow #flags: 40 #isOpaque: true #model: #removeRow #label: 'Delete' #isDefault: false ) #(#ActionButtonSpec #layout: #(#Rectangle 276 6 341 31 ) #name: #cancel #flags: 40 #isOpaque: true #model: #cancel #label: 'Cancel' #isDefault: false ) #(#ActionButtonSpec #layout: #(#Rectangle 211 6 276 31 ) #name: #accept #flags: 40 #isOpaque: true #model: #accept #label: 'Accept' #isDefault: false ) ) ) )
</methods> <methods> Examples.BorrowerMgrExample <category>query</category>
ownQuery "This method was generated by UIDefiner. Any edits made here will be lost if the class is regenerated anew." "QueryEditor new openOnClass: self andSelector: #ownQuery" <resource: #query> | _qo | _qo := LensQuery new. _qo description: 'ownQuery'. _qo arrayContainerNames: #((#borrowerexample #BorrowerExample) ). _qo mode: #own. ^_qo
</methods> <methods> Examples.BorrowerMgrExample class <category>interface specs</category>
windowSpec "UIPainter new openOnClass: self andSelector: #windowSpec" <resource: #canvas> ^#(#FullSpec #window: #(#WindowSpec #label: 'BorrowerMgrExample' #bounds: #(#Rectangle 335 450 804 658 ) ) #component: #(#SpecCollection #collection: #( #(#DataSetSpec #layout: #(#LayoutFrame 0 0 43 0 0 1.0 -1 1 ) #name: #rows #model: #rows #callbacksSpec: #(#UIEventCallbackSubSpec #requestValueChangeSelector: #rowChangeRequest ) #columns: #( #(#DataSetColumnSpec #labelIsImage: false #width: 30 #rendererType: #rowSelector #editorType: #rowSelector #noScroll: false ) #(#DataSetColumnSpec #model: #'row @ borrowerexample librarycard | trigger' #callbacksSpec: #(#UIEventCallbackSubSpec #valueChangeSelector: #valueChanged #requestFocusInSelector: #focusInRequest ) #label: 'Library Card' #labelIsImage: false #width: 120 #rendererType: #Text #editorType: #None #font: #system #alignment: #left #type: #number #noScroll: false ) #(#DataSetColumnSpec #model: #'row @ borrowerexample name | trigger' #callbacksSpec: #(#UIEventCallbackSubSpec #valueChangeSelector: #valueChanged #requestFocusInSelector: #focusInRequest ) #label: 'Name' #labelIsImage: false #width: 200 #rendererType: #Text #editorType: #InputField #size: 30 #font: #system #alignment: #left #type: #string #noScroll: false ) #(#DataSetColumnSpec #model: #'row @ borrowerexample address | trigger' #callbacksSpec: #(#UIEventCallbackSubSpec #valueChangeSelector: #valueChanged #requestFocusInSelector: #focusInRequest ) #label: 'Address' #labelIsImage: false #width: 300 #rendererType: #Text #editorType: #InputField #size: 60 #font: #system #alignment: #left #type: #string #noScroll: false ) ) ) #(#ActionButtonSpec #layout: #(#Rectangle 11 6 76 31 ) #name: #addRow #isOpaque: true #model: #addRow #label: 'New' #isDefault: false ) #(#ActionButtonSpec #layout: #(#Rectangle 76 6 141 31 ) #name: #removeRow #flags: 40 #isOpaque: true #model: #removeRow #label: 'Delete' #isDefault: false ) #(#ActionButtonSpec #layout: #(#Rectangle 206 6 271 31 ) #name: #cancel #flags: 40 #isOpaque: true #model: #cancel #label: 'Cancel' #isDefault: false ) #(#ActionButtonSpec #layout: #(#Rectangle 141 6 206 31 ) #name: #accept #flags: 40 #isOpaque: true #model: #accept #label: 'Accept' #isDefault: false ) ) ) )
</methods> "Imported Classes:" self error: 'Attempting to file-in parcel imports. Choose terminate or close' <class> <name>Object</name> <environment>Core</environment> <super></super> <private>false</private> none <imports></imports> <category>Kernel-Objects</category> <attributes> <package>Kernel-Objects</package> </attributes> </class> <class> <name>LensDataManager</name> <environment>Lens</environment> <super>Lens.LensApplicationModel</super> <private>false</private> none rows row trigger rowCount isEditing isCreating isDirty lockPolicy rowType <imports></imports> <category>Lens-Applications-Framework</category> <attributes> <package>Lens-Runtime</package> </attributes> </class> <class> <name>LensMainApplication</name> <environment>Lens</environment> <super>Lens.LensApplicationModel</super> <private>false</private> none <imports></imports> <category>Lens-Applications-Framework</category> <attributes> <package>Lens-Runtime</package> </attributes> </class>