ThelopWiki

Wards Wiki Pages / Thelop Name Pattern

ThelopNamePattern?'s are used to restrict the possible arrangements of ThelopWord?s used for ThelopName?'s.


The ThelopNamePattern?'s are written using the abbreviations for the ThelopWordClass?es: Objects (O), Actions (A), Properties (P) and Modifiers (M). An appended + character means that there may be one or more repetitions of the same word class (P+ stands for P, PP, PPP' ...)

Any object or property word (O or P) may be followed by one or more modifier words (M), that may change the WordSignature? (meaning, corresponding parameters) of the "parent word".

Any complete name may be followed by one or more modifiers that change the meaning of the whole function. These modifiers are called "global modifiers".

A complete name may have a phrase "R'etObject" or "R'etProperty" added, to display what the function returns. If this is obvious, the phrase may be dropped. See: ThelopRule?.


A "basic ThelopNamePattern?" is a pattern with no modifiers. Only basic patterns are listed here. Examples are given with and without added modifiers.


Basic pattern: OA (ObjectAction)

used for unary actions.

Examples: S'creenClear(), FileDel(filename), WindowClose(window), ImageFree(image), WindowCloseAll(), I'mageCvtColorspaceGray(image)


Basic pattern OAP+ (ObjectActionProperties)

typically used for accessing object properties by using the "Set" or "Get" actions.

Examples: F'ileSetSize(filename,size), SystemG?etUserName(pString), ImageGetWidthHeight(image,pWidth,pHeight), WindowSetRect(window,rectangle), I'mageGetPixel(image,x,y,pColor), I'mageGetPixelGray(image,x,y,&pColorGray), W'indowGetChildFirst(window,pChildWindow)


Basic pattern: OAO (ObjectActionObject)

used for binary actions.

Examples: S'trFindChr(string,character), FileAppLine(filename,string), ImageCreateFile(filename), RectCmp(rectangle1, rectangle2), PointInPoligon(point,poligon), F'ileLockPosSizeRetErr(file,position,size),

Comments: According to ThelopRule? the second object word may be dropped if it is identical to the primary object word ("R'ectCmp" instead of "R'ectCmpRect").


(work in progress...)
See also: LanguageOrientedProgramming, ThelopLanguage?, ThelopRule?, ThelopWordExample?, ThelopNameExample?, ThelopDictionary
CategoryThelop?
 
© ThelopWiki Community zuletzt geändert am September 22, 2003