OSSP CVS Repository

ossp - Check-in [2194]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 2194
Date: 2002-Jun-27 15:48:19 (local)
2002-Jun-27 13:48:19 (UTC)
User:ps
Branch:
Comment: Tabea brainstorming. Brainstorming about configuration by THL and PS
Tickets:
Inspections:
Files:
ossp-pkg/tabea/tabea-brainstorming      added-> 1.1

ossp-pkg/tabea/tabea-brainstorming -> 1.1

*** /dev/null    Sat Nov 23 01:27:39 2024
--- -    Sat Nov 23 01:27:47 2024
***************
*** 0 ****
--- 1,547 ----
+ 
+     Terminology
+ 
+     structure - structure of the user interface
+     template  - skeleton(s) of the output file(s) with variables which need expansion using the choices
+     data      - file that contains the data chosen by the user
+     output    - file(s) actually written out by tabea.
+ 
+     Files
+ 
+     - output
+     
+     One or more files being written out by tabea. It is/they are build
+     from template(s) by expanding the embedded variables using lib_var
+     with data from the choices file. The output files are usually
+     write-only except an import function is provided to build a baseline
+     of choice from a pre-existing output, which is typically the case
+     when someone has maintained such a file manually before it was taken
+     under tabea control or such a file is received from an external
+     source.
+ 
+     - data
+ 
+     A single file containing all data chosen by the user.  Format is one
+     record per logical line. A physical line be extended to a long
+     logical line using a trailing BACKSLASH just before the NEWLINE.
+     Fields are separated by SPACE. Unused optional fields must be filled
+     using a DASH.  The following fields exist:
+ 
+     name (mandatory)
+     value (optional)
+ 
+     A name might end with SQUARE BRACKET OPEN, any integer and SQUARE
+     BRACKET CLOSE, indicating an array. If the integer or the wholly
+     squre bracket construct is omited, [0] is assumed.
+ 
+     - template
+ 
+     Any ASCII file using lib_var syntax for variable expansion.
+ 
+     - structure of a item block
+ 
+     Menu structure of the user interface.  Format is one record per
+     logical line. A physical line be extended to a long logical line
+     using a trailing BACKSLASH just before the NEWLINE. Fields are
+     separated by SPACE. Unused optional fields must be filled using a
+     DASH.  The following fields exist:
+ 
+     block {
+         name (mandatory)
+         visible
+         description
+         helptext
+         helpurl
+         activate
+         item {
+             name (mandatory)
+             namevisible
+             description
+             helptext
+             helpurl
+             type
+             defaultvalue
+             value {
+                 name (mandatory)
+                 visible
+                 description
+                 helptext
+                 helpurl
+                 verify
+             }
+         }
+     }
+     
+     A name might end with SQUARE BRACKET OPEN, any integer and SQUARE
+     BRACKET CLOSE, indicating an array. If the integer or the wholly
+     squre bracket construct is omited, [0] is assumed.
+ 
+     A description is a human readable text for name. If omited, name is
+     used verbatim.
+ 
+     A helptext is a human readable text for the word "help". If omitted
+     and "helpurl" is set, it defaults to "help". If "helpurl" is omitted
+     no help link is shown at all.
+ 
+     The helpurl is the URL to a help page describing the item.
+ 
+     The defaultvalue is taken if the name is omitted in the data file,
+     i.e. the data file did not previously exist, was modfied through an
+     external mechanism or an updated structure added a name which did
+     not exist in previous versions. It is also used if the
+     structure validation failed.
+     
+     A valuehelptext is a human readable text for the word "help". If omitted
+     and "valuehelpurl" is set, it defaults to "help". If "valuehelpurl" is omitted
+     no help link is shown at all.
+ 
+     The valuehelpurl is the URL to a help page describing the value.
+ 
+     The "verify" is a regex.
+ 
+     The "eval" is a little perl program and uses perl's "eval" to find
+     out the result.
+     Possible types are taken from RFC1866, Section 8.1.2 - 8.1.4
+ 
+     8.1.2.1. Text Field: INPUT TYPE=TEXT
+ 
+     <p>Street Address: <input name=street><br>
+     Postal City code: <input name=city size=16 maxlength=16><br>
+     Zip Code: <input name=zip size=10 maxlength=10 value="99999-9999"><br>
+ 
+     item {
+         name street
+         visible "Street Address:"
+         type text
+     }
+     item {
+         name city
+         visible "Postal City code:"
+         type text[16][16]
+     }
+     item {
+         name zip
+         visible "Zip Code:"
+         type text[10][10]
+         value {
+             name "99999-9999"
+         }
+     }
+ 
+     8.1.2.2. Password Field: INPUT TYPE=PASSWORD
+ 
+     <p>Name: <input name=login> Password: <input type=password name=passwd>
+ 
+     item {
+         name login
+         visible "Name:"
+         type text
+     }
+     item {
+         name passwd
+         visible "Password:"
+         type password
+     }
+ 
+ 
+     8.1.2.3. Check Box: INPUT TYPE=CHECKBOX
+ 
+     <p>What flavors do you like?
+     <input type=checkbox name=flavor value=vanilla checked>Vanilla<br>
+     <input type=checkbox name=flavor value=strawberry>Strawberry<br>
+     <input type=checkbox name=flavor value=chocolate checked>Chocolate<br>
+ 
+     item {
+         name flavor
+         visible "What flavors do you like?"
+         type checkbox
+         value {
+             name vanilla
+             visible "Vanilla"
+             checked
+         }
+         value {
+             name strawberry
+             visible "Strawberry"
+         }
+         value {
+             name chocolate
+             visible "Chocolate"
+             checked
+         }
+     }
+ 
+     8.1.2.4. Radio Button: INPUT TYPE=RADIO
+ 
+     <p>Which is your favorite?
+     <input type=radio name=flavor value=vanilla checked>Vanilla<br>
+     <input type=radio name=flavor value=strawberry>Strawberry<br>
+     <input type=radio name=flavor value=chocolate>Chocolate<br>
+ 
+     item {
+         name flavor
+         visible "Which is your favorite?"
+         type radio
+         value {
+             name vanilla
+             visible "Vanilla"
+             checked
+         }
+         value {
+             name strawberry
+             visible "Strawberry"
+         }
+         value {
+             name chocolate
+             visible "Chocolate"
+         }
+     }
+ 
+     8.1.2.5. Image Pixel: INPUT TYPE=IMAGE
+ 
+     item {
+         name point
+         visible "Choose a point on the map:"
+         type image
+         value {
+             name "map.gif"
+         }
+     }
+ 
+     8.1.2.6. Hidden Field: INPUT TYPE=HIDDEN (FIXME do we really need this?)
+ 
+     <input type=hidden name=context value="l2k3j4l2k3j4l2k3j4lk23">
+ 
+     item {
+         name context
+         type hidden
+         value {
+             name "l2k3j4l2k3j4l2k3j4lk23"
+         }
+     }
+ 
+     8.1.2.7. Submit Button: INPUT TYPE=SUBMIT
+ 
+     <input type=submit name=recipient value=internal><br>
+     <input type=submit name=recipient value=world>
+ 
+     item {
+         name recipient
+         type submit
+         value {
+             name internal
+         }
+         value {
+             name world
+         }
+     }
+ 
+     8.1.2.8. Reset Button: INPUT TYPE=RESET
+ 
+     You may clear the form and start over at any time: <input type=reset>
+ 
+     item {
+         description "You may clear the form and start over at any time:"
+         type reset
+     }
+ 
+     8.1.3. Selection: SELECT
+     8.1.3.1. Option: OPTION
+ 
+     <SELECT NAME="flavor" SIZE="2">
+     <OPTION>Vanilla
+     <OPTION>Strawberry
+     <OPTION value="RumRasin">Rum and Raisin
+     <OPTION selected>Peach and Orange
+     </SELECT>
+ 
+     item {
+         name flavor
+         type select[2] //or type selectmultipe[2]
+         value {
+             name "Vanilla"
+         }
+         value {
+             name "Strawberry"
+         }
+         value {
+             name RumRasin
+             visible "Rum and Raisin"
+         }
+         value {
+             name "Peach and Orange"
+             selected
+         }
+ 
+     }
+ 
+     8.1.4. Text Area: TEXTAREA
+ 
+     <TEXTAREA NAME="address" ROWS=6 COLS=64>
+     HaL Computer Systems
+     1315 Dell Avenue
+     Campbell, California 95008
+     </TEXTAREA>
+ 
+     item {
+         name "address"
+         type textarea[64][6]
+         value {
+             name "HaL Computer Systems\n1315 Dell Avenue\nCampbell, California 95008"
+         }
+     }
+ 
+     Example: Generic RAID configuration
+ 
+     block {
+         name BEGIN
+         visible "RAID configurator"
+         description "Please configure your redundant array of independent disks now"
+         helptext info
+         helpurl http://www.raid.org
+         activate #always
+         item {
+             name numdrives
+             visible "Number of drives [1...9]"
+             description "enter the total number of drives in the array including redundant and spare drives"
+             helptext ?
+             helpurl http://www.counting.org/basics
+             activate #always
+             type text[1]
+             defaultvalue 1
+             verify ^[123456789]$
+             eval $numdrives ~= ^[123456789]$
+         }
+         item {
+             name raidlevel
+             activate numdrives~=.
+             type radio
+             defaultvalue 0
+             value {
+                 name 0
+                 visible "RAID 0"
+             }
+             value {
+                 name 1
+                 activate numdrives~=^[2468]$ #even
+             }
+             value {
+                 name 4
+                 activate numdrives~=^[3456789]$ #>=3
+             }
+             value {
+                 name 5
+                 activate numdrives~=^[3456789]$ #>=3
+             }
+             value {
+                 name 10
+                 activate numdrives~=^[48]$ #multiple of 4
+             }
+             value {
+                 name 1+HOT
+                 activate numdrives~=^[3579]$ #odd AND >=3
+             }
+             value {
+                 name 4+HOT
+                 activate numdrives~=^[456789]$ #>=4
+             }
+             value {
+                 name 5+HOT
+                 activate numdrives~=^[456789]$ #>=4
+             }
+         }
+     }
+     block {
+         name END
+         visible "commit suicide now"
+         activate numdrives~=. && raidlevel~=^[0145](+HOT)?$
+         item {
+             name "Finish"
+             type button
+         }
+     }
+ 
+ Example: Jumpstart Disk and Raid Configuration
+ 
+     block {
+         name BEGIN
+         visible "Disk Configuration"
+         description "Please configure the number of disks and the RAID"
+         helptext info
+         helpurl 
+         activate #always
+         item {
+             name numdrives
+             visible "Number of drives [1...9]"
+             description "enter the total number of drives in the array including redundant and spare drives"
+             helptext ?
+             helpurl http://www.counting.org/basics
+             activate #always
+             type text[1]
+             (type popup_menu[1] )
+             defaultvalue 1
+             verify ^[12]$
+         }
+         item {
+             name raidlevel
+             activate numdrives~=.
+             type radio
+             defaultvalue 0
+             item
+             value {
+                 name 0
+                 visible "RAID 0"
+             }
+             value {
+                 name 1
+                 activate numdrives~=^[2]$ #even
+             }
+         }
+         item {
+             name sizeofdisk
+             
+         }
+         item {
+             name slices
+             visible 'Slice definition'
+             item {
+                 name slice0
+                 visible "Definition of slice0"
+                 item {
+                     name size
+                     visible "Define the size of sclice"
+                     verify sizeofdisk - size0 - size1 ..... -size7 >= 0
+                 }
+                 item {
+                     name moutpoint 
+                     visible "Define the mount point of slice"
+                     type popup_menu[7}  # Dependencies to other slice types
+                     verify              # Depencies to other slices
+                 }               
+ 
+             item {
+                 name slice1
+                 visible "Definition of slice1"
+                 item {
+                     name size
+                     visible "Define the size of sclice"
+                 }
+                 item {
+                     name moutpoint 
+                     visible "Define the mount point of slice"
+                     type popup_menu[7}  # Dependencies to other slice types
+                     verify              #                
+                 }
+ 
+             item {
+                 name slice2
+                 visible "Definition of slice2"
+                 item {
+                     name size
+                     visible "Define the size of sclice"
+                 }
+                 item {
+                     name moutpoint 
+                     visible "Define the mount point of slice"
+                     type popup_menu[7}  # Dependencies to other slice types
+                     verify              #           
+                 }
+             item {
+                 name slice3
+                 visible "Definition of slice3"
+                 item {
+                     name size
+                     visible "Define the size of sclice"
+                 }
+                 item {
+                     name moutpoint 
+                     visible "Define the mount point of slice"
+                     type popup_menu[7}  # Dependencies to other slice types
+                     verify              #           
+                 }
+             item {
+                 name slice4
+                 visible "Definition of slice4"
+                 item {
+                     name size
+                     visible "Define the size of sclice"
+                 }
+                 item {
+                     name moutpoint 
+                     visible "Define the mount point of slice"
+                     type popup_menu[7}  # Dependencies to other slice types
+                     verify              #           
+                 }
+             item {
+                 name slice5
+                 visible "Definition of slice5"
+                 item {
+                     name size
+                     visible "Define the size of sclice"
+                 }
+                 item {
+                     name moutpoint 
+                     visible "Define the mount point of slice"
+                     type popup_menu[7}  # Dependencies to other slice types
+                     verify              #           
+                 }
+             item {
+                 name slice6
+                 visible "Definition of slice6"
+                 item {
+                     name size
+                     visible "Define the size of sclice"
+                 }
+                 item {
+                     name moutpoint 
+                     visible "Define the mount point of slice"
+                     type popup_menu[7}  # Dependencies to other slice types
+                     verify              #           
+                 }
+             item {
+                 name slice7
+                 visible "Definition of slice7"
+                 item {
+                     name size
+                     visible "Define the size of sclice"
+                     
+                 }
+                 item {
+                     name moutpoint 
+                     visible "Define the mount point of slice"
+                     type popup_menu[7}  # Dependencies to other slice types 
+                     verify              #                
+                 }
+ 
+ 
+ 
+ 
+ 
+ 
+              } 
+ 
+              
+             }
+             
+         }
+         
+     }
+     block {
+         name pruefen
+         type submit
+     }
+     block {
+         name clean
+         type reset
+     }
+     block {
+         name END
+         visible "commit suicide now"
+         activate numdrives~=. && raidlevel~=^[0145](+HOT)?$
+         item {
+             name "Finish"
+             type button
+         }
+     }
+ 
+ 

CVSTrac 2.0.1