OOFILE  1.9
Public Member Functions | Protected Attributes | List of all members
dbUshortLink Class Reference

Link a dbUshort field to a LControl eg: checkbox. More...

#include <oofpp.h>

Inheritance diagram for dbUshortLink:
Inheritance graph
[legend]
Collaboration diagram for dbUshortLink:
Collaboration graph
[legend]

Public Member Functions

void createDirtySensor (LPane *) const
 
 dbUshortLink (dbUshort *fld, LControl *ctl, bool becomeReadOnly)
 
 dbUshortLink (dbUshort *fld, LControl *ctl, bool becomeReadOnly, bool)
 
virtual void describe (std::ostream &) const
 Provide human-readable information about object. More...
 
dbUshortfield () const
 
bool hidden () const
 
void hide (bool hideIt=true)
 
LPanelinksTo () const
 
virtual oofString name () const
 
dbHelperowner () const
 
void owner (dbHelper *)
 not ctor param as can create without helper More...
 
void setField (dbField *inField)
 
mainly used by dbGUIadaptor
void maybeChangeTargetLink ()
 
void maybeDirty ()
 
virtual void tellGUIcareAboutLocking () const
 
mainly used by dbEditHelper
virtual void copyFieldToLink ()
 
virtual void copyLinkToField ()
 
virtual bool linkEqualsField () const
 
virtual bool leaveLink ()
 
virtual void updateDerivedFieldDisplay (bool isNew)
 
virtual void readOnly (bool isReadOnly=true)
 Change readonly state of link to accept or deny data entry. More...
 
virtual bool validToLeaveLink ()
 Validate field contents, overridden if can check just contents. More...
 
virtual bool validToLeaveForm ()
 Validate unique fields to ensure can accept this record without error from database. More...
 
virtual void highlightLink ()
 Visually highlight a link, usually becoming edit focus. More...
 
void markClean ()
 
reflective calls
bool isReadOnly () const
 
bool alwaysReadOnly () const
 
bool isDirty () const
 
bool linkIsEmpty () const
 
dbGUIAdapteradapter () const
 

Protected Attributes

dbGUIAdaptermAdapter
 owned More...
 
bool mAlwaysReadOnly
 for static controls, etc; More...
 
dbFieldmField
 
bool mHidden
 
LPanemLinksTo
 use this for obsolete subclass, ignoring adapters More...
 
bool mMaybeDirty
 tentative flag lets us optimise comparisons More...
 
dbHelpermOwner
 
bool mReadOnly
 default is read-write More...
 

Detailed Description

Link a dbUshort field to a LControl eg: checkbox.

Note
Concrete link used directly by name in previous OOFILE apps and so reimplemented when we moved to the generic structure.
See also
linkField(dbField*, LControl*) generic link implementation.

Definition at line 483 of file oofpp.h.

Constructor & Destructor Documentation

dbUshortLink::dbUshortLink ( dbUshort fld,
LControl *  ctl,
bool  becomeReadOnly 
)
inline

Definition at line 485 of file oofpp.h.

dbUshortLink::dbUshortLink ( dbUshort fld,
LControl *  ctl,
bool  becomeReadOnly,
bool   
)
inline

Definition at line 490 of file oofpp.h.

Member Function Documentation

dbGUIAdapter * dbFieldLink::adapter ( ) const
inlineinherited

Definition at line 815 of file oofgui.h.

References dbFieldLink::mAdapter.

Referenced by dbAbstractEditHelper::getLink().

bool dbFieldLink::alwaysReadOnly ( ) const
inlineinherited

Definition at line 770 of file oofgui.h.

References dbFieldLink::mAlwaysReadOnly.

void dbFieldLink::copyFieldToLink ( )
virtualinherited
void dbFieldLink::copyLinkToField ( )
virtualinherited
void dbUshortLink::createDirtySensor ( LPane ) const
inline

Definition at line 498 of file oofpp.h.

void OOF_PublicBase::describe ( std::ostream &  ) const
virtualinherited

Provide human-readable information about object.

Overriden to provide much more detail particularly for dbTable::describe() which provides full schema.

Reimplemented in dbConnect, dbTable, dbFixedBinary, dbChar, dbField, and dbRelRefBase.

Definition at line 342 of file oof1.cpp.

References OOF_PublicBase::name().

Referenced by OOF_Dictionary::describeVisible().

dbUshort* dbUshortLink::field ( ) const
inline

Definition at line 495 of file oofpp.h.

References dbFieldLink::mField.

bool OOF_PublicBase::hidden ( ) const
inlineinherited

Definition at line 51 of file oof1.h.

Referenced by OOF_Dictionary::EntryMatchesVisibility().

void OOF_PublicBase::hide ( bool  hideIt = true)
inlineinherited

Definition at line 52 of file oof1.h.

void dbFieldLink::highlightLink ( )
virtualinherited

Visually highlight a link, usually becoming edit focus.

dbAbstractEditHelper::ValidateLinks calls us to highlight the first invalid link it finds.

Definition at line 1044 of file oofgui.cpp.

References dbGUIAdapter::highlightContents(), and dbFieldLink::mAdapter.

Referenced by dbAbstractEditHelper::ValidateLinks().

bool dbFieldLink::isDirty ( ) const
inlineinherited
bool dbFieldLink::isReadOnly ( ) const
inlineinherited

Definition at line 763 of file oofgui.h.

References dbFieldLink::mReadOnly.

Referenced by dbGUIAdaptLControl::ExecuteSelf(), and dbGUIAdapter::IsReadOnly().

bool dbFieldLink::leaveLink ( )
virtualinherited
bool dbFieldLink::linkEqualsField ( ) const
virtualinherited
bool dbFieldLink::linkIsEmpty ( ) const
inherited
LPane* dbUshortLink::linksTo ( ) const
inline

Definition at line 496 of file oofpp.h.

References mLinksTo.

void dbFieldLink::markClean ( )
inlineinherited
void dbFieldLink::maybeChangeTargetLink ( )
inlineinherited
void dbFieldLink::maybeDirty ( )
inlineinherited
oofString OOF_PublicBase::name ( ) const
virtualinherited

Reimplemented in dbConnect, dbTable, OOF_adornerHolder, and dbField.

Definition at line 349 of file oof1.cpp.

Referenced by OOF_PublicBase::describe().

dbHelper * dbFieldLink::owner ( ) const
inlineinherited
void dbFieldLink::owner ( dbHelper inOwner)
inlineinherited

not ctor param as can create without helper

Definition at line 787 of file oofgui.h.

References dbFieldLink::mOwner.

void dbFieldLink::readOnly ( bool  becomeReadOnly = true)
virtualinherited

Change readonly state of link to accept or deny data entry.

Won't allow enabling editing if can't edit record due to locking.

Definition at line 1133 of file oofgui.cpp.

References dbTable::getGUI(), dbFieldLink::mAlwaysReadOnly, dbFieldLink::mOwner, dbFieldLink::mReadOnly, dbGUI::recordAvailable(), and dbHelper::table().

Referenced by oofRepLayoutEditLink::getCellText(), oofRepViewEditLink::getCellText(), and oofRepColHeaderEditLink::getCellText().

void dbFieldLink::setField ( dbField inField)
inlineinherited

Definition at line 822 of file oofgui.h.

References dbFieldLink::mField.

void dbFieldLink::tellGUIcareAboutLocking ( ) const
virtualinherited
void dbFieldLink::updateDerivedFieldDisplay ( bool  isNew)
virtualinherited
bool dbFieldLink::validToLeaveForm ( )
virtualinherited

Validate unique fields to ensure can accept this record without error from database.

Warning
you probably still want to call this method if you override.

Reimplemented in dbFieldPickLink.

Definition at line 1110 of file oofgui.cpp.

References dbField::copyString(), dbField::fieldIsUniqueIndexed(), dbField::fieldName(), dbFieldLink::mField, dbFieldLink::validToLeaveLink(), and dbField::valueIsDuplicate().

Referenced by dbAbstractEditHelper::ValidateLinks().

bool dbFieldLink::validToLeaveLink ( )
virtualinherited

Validate field contents, overridden if can check just contents.

Lightweight check that allows tabbing between fields in open record.

See also
validToLeaveForm for heavier check.
dbDateLink2Editor::validToLeaveLink

Reimplemented in dbDateTimeLink2Editor, and dbDateLink2Editor.

Definition at line 1099 of file oofgui.cpp.

Referenced by dbFieldLink::leaveLink(), dbFieldPickLink::leaveLink(), and dbFieldLink::validToLeaveForm().

Member Data Documentation

dbGUIAdapter* dbFieldLink::mAdapter
protectedinherited
bool dbFieldLink::mAlwaysReadOnly
protectedinherited

for static controls, etc;

Definition at line 238 of file oofgui.h.

Referenced by dbFieldLink::alwaysReadOnly(), and dbFieldLink::readOnly().

dbField* dbFieldLink::mField
protectedinherited
bool OOF_PublicBase::mHidden
protectedinherited

Definition at line 61 of file oof1.h.

LPane* dbUshortLink::mLinksTo
protected

use this for obsolete subclass, ignoring adapters

Definition at line 498 of file oofpp.h.

Referenced by linksTo().

bool dbFieldLink::mMaybeDirty
protectedinherited

tentative flag lets us optimise comparisons

Definition at line 236 of file oofgui.h.

Referenced by dbFieldLink::isDirty(), dbFieldLink::leaveLink(), dbFieldLink::markClean(), and dbFieldLink::maybeDirty().

dbHelper* dbFieldLink::mOwner
protectedinherited
bool dbFieldLink::mReadOnly
protectedinherited

default is read-write

Definition at line 237 of file oofgui.h.

Referenced by dbFieldLink::isReadOnly(), and dbFieldLink::readOnly().


The documentation for this class was generated from the following file: