annotate
apropos
catcr
catcs
cc.icon
cc.magic
cd
chactivity
chbl
checkin
checkout
checkvob
chevent
chflevel
chfolder
chmaster
chpool
chproject
chstream
chtype
chview
clearaudit
clearbug
cleardescribe
cleardiffbl
cleardiff
clearexport_ccase
clearexport_cvs
clearexport_pvcs
clearexport_rcs
clearexport_sccs
clearexport_ssafe
clearfsimport
cleargetlog
clearhistory
clearimport
clearjoinproj
clearlicense
clearmake
clearmake.options
clearmrgman
clearprojexp
clearprompt
cleartool
clearviewupdate
clearvobadmin
comments
config_ccase
config_spec
cptype
credmap
creds
deliver
describe
diffbl
diffcr
diff
dospace
edcs
endview
env_ccase
events_ccase
export_mvfs
exports_ccase
file
find
findmerge
fmt_ccase
getcache
get
getlog
help
hostinfo
init_ccase
ln
lock
lsactivity
lsbl
lscheckout
lsclients
lscomp
lsdo
lsfolder
lshistory
ls
lslock
lsmaster
lspool
lsprivate
lsproject
lsregion
lsreplica
lssite
lsstgloc
lsstream
lstype
lsview
lsvob
lsvtree
makefile_aix
makefile_ccase
makefile_gnu
makefile_pmake
makefile_smake
makefile_sun
man
merge
mkactivity
mkattr
mkattype
mkbl
mkbranch
mkbrtype
mkcomp
mkdir
mkelem
mkeltype
mkfolder
mkhlink
mkhltype
mklabel
mklbtype
mkpool
mkproject
mkregion
mkstgloc
mkstream
mktag
mktrigger
mktrtype
mkview
mkvob
mount_ccase
mount
msdostext_mode
mvfslog
mvfsstorage
mvfstime
mvfsversion
mv
omake
pathnames_ccase
permissions
profile_ccase
promote_server
protect
protectvob
pwd
pwv
query_language
quit
rebase
recoverview
reformatview
reformatvob
register
relocate
rename
reqmaster
reserve
rgy_backup
rgy_check
rgy_passwd
rgy_switchover
rmactivity
rmattr
rmbl
rmbranch
rmcomp
rmdo
rmelem
rmfolder
rmhlink
rmlabel
rmmerge
rmname
rmpool
rmproject
rmregion
rmstgloc
rmstream
rmtag
rmtrigger
rmtype
rmver
rmview
rmvob
schedule
schemes
scrubber
setactivity
setcache
setcs
setplevel
setsite
setview
shell
snapshot.conf
softbench_ccase
space
startview
type_manager
umount
uncheckout
unlock
unregister
unreserve
update
version_selector
view_scrubber
vob_restore
vob_scrubber
vob_sidwalk
vob_snapshot
vob_snapshot_setup
wildcards_ccase
winkin
xclearcase
xcleardiff
xmldiffmrg
SYNOPSIS
- mkeltype [ –rep·lace ] [ –glo·bal [ –acq·uire ] | –ord·inary ]
- –sup·ertype elem-type-selector [ –man·ager mgr-name ]
[ –pti·me ] [ –att·ype attr-type-selector[,...] ]
[ –mer·getype { auto | user | never } ]
[ –c·omment comment | –cfi·le comment-file-pname |–cq·uery
| –cqe·ach | –nc·omment ] element-type-selector ...
DESCRIPTION
The mkeltype command creates one or more user-defined element types for future use within a VOB. User-defined element types are variants of the predefined types. (See complete list in the section “Predefined Element Types”.) After creating an element type, you can create elements of that type by using mkelem, or you can change an existing element's type by using chtype. To remove an element type, use the rmtype command.
Note: You cannot remove an element type from a replicated VOB or change the definition of an element type in a replicated VOB.
Setting Merge Behavior for an Element Type
In some cases, you can select the merge behavior of an element type when you create it. This is true for element types of elements used in a UCM deliver or rebase operation. (See the deliver and rebase reference pages). There are three kinds of behaviors, described here with their associated keywords.
To specify a behavior, use one of the keywords as the argument to the –mergetype option. If the option is not specified, automatic merge behavior is in effect for elements of this element type.
Element Supertypes
When you create a new element type, you must specify an existing element type as its supertype. The new element type inherits the type manager of the supertype, unless you use the –manager option. The type manager performs such tasks as storing/retrieving the contents of the element's versions. (See the type_manager reference page.)
For example, you create an element type c_source, with text_file as the supertype; c_source inherits the type manager associated with the text_file supertype—the text_file_delta manager.
You can use the lstype command to list both the supertype and the type manager of an element type.
Predefined Element Types
Each VOB is created with the following element types:
You can use any of these element types as the –supertype specification.
Text Files, Cleartext, and a View's Text Mode
This section applies to the element types text_file and compressed_text_file, to all subtypes of these types, and to all user-defined element types derived from them through the supertype mechanism.
When a load operation is issued from a snapshot view, or a user program accesses a version through a dynamic view, the type manager handles it as follows:
- Extracts the text lines of that particular version from the data container.
- Stores the extracted lines in a cleartext file, within the cleartext storage pool directory associated with the element.
- Arranges for the program to access the cleartext file (not the structured data container).
On subsequent accesses to the same version, steps 1 and 2 are skipped; the program accesses the existing cleartext file, which is cached in the cleartext storage pool.
Operating systems vary in their use of text-file line terminators. To avoid confusion, each ClearCase and ClearCase LT view has a text mode, which determines the line terminator for text files in that view. (See the mkview reference page.) After the type manager constructs a cleartext file for a version, its line terminators may be adjusted before the version is presented to the calling program. Adjustment of line terminators can also occur when the checkout command copies a version of a text file element, creating a view-private file (the checked-out version).
RESTRICTIONS
Identities
No special identity is required unless you specify the –replace option. For –replace, you must have one of the following identities:
OPTIONS AND ARGUMENTS
Handling of Name Collisions
- Default
- An error occurs if an element type named type-name already
exists in the VOB.
- –rep·lace
- Replaces the existing definition of type-name with
a new one. If you do not include options from the existing definition, their
values are replaced with the defaults. (Exception: the type's scope does not
change unless you explicitly specify a –global or –ordinary option.)
If you specify a comment when using –replace, the comment appears in the event record for the modification (displayed with lshistory –minor); it does not replace the object's creation comment (displayed with describe). To change an object's creation comment, use chevent.
You cannot change the following:
- The type manager (–manager or –supertype option)
if there are existing elements of the type type-name,
or if there are existing elements that are of subtytpes of the type type-name.
- The definition of a predefined element type (such as file or text_file)
Also, when converting a global type to ordinary, you must specify the global type as the element-type-selector argument. You cannot specify a local copy of the global type.
- The type manager (–manager or –supertype option)
if there are existing elements of the type type-name,
or if there are existing elements that are of subtytpes of the type type-name.
Specifying the Scope of the Element Type
- Default
- Creates an ordinary element type that can
be used only in the current VOB.
- –glo·bal [ –acq·uire ]
- Creates an element type that can be used
as a global resource by the VOBs in the administrative VOB hierarchy. With –acquire, mkeltype checks
all eclipsing types in the VOBs and converts them to local copies of the new
global type.
For more information, see the Administrator's Guide.
- –ord·inary
- Creates an element type that can be used
only in the current VOB.
Supertype / Type Manager Inheritance
- Default
- None. You must specify a supertype; the
new element type inherits the type manager of this supertype, unless you use
the –manager option.
- –sup·ertype elem-type-selector
- The name of an existing element type, predefined
or user-defined. Predefined element types are listed in “Predefined
Element Types”. You can specify –supertype file_system_object only
if you also specify a type manager with –manager.
Specify element-type-selector in the form [eltype:]type-name[@vob-selector]
The lstype command lists a VOB's existing element types.
- –man·ager mgr-name
- Specifies the type manager for the new
element type, overriding inheritance from the supertype. The section “Predefined
Element Types” lists the type managers.
For more information about these type managers, see the type_manager reference
page.
Controlling Version-Creation Time
- Default
- For all elements of the newly created type:
when a new version is checked in, its time stamp is set to the checkin time.
- –pti·me
- For all elements of the newly created type:
preserves the time stamp of the checked-out version during checkin. In effect,
this establishes checkin –ptime as
the default for elements of this type.
Mergetype
- Default
- Instantiations of the new element type
use automatic merging.
- –mer·getype keyword
- Specifies the merge behavior for an element
type. This is in effect only when the element type is used in a UCM deliver
or rebase operation. There are three types of merge behavior: automatic, for
which a findmerge operation attempts to
automatically merge elements; user-controlled, for which a findmerge operation
performs trivial merges only (other merges must be made manually); and never,
meaning findmerge ignores elements of this
type. The corresponding keyword arguments are auto, user,
and never; auto is the default.
Suggested Attributes
- Default
- The new element type has no list of suggested
attributes.
- –att·ype attr-type-selector[,...]
- A comma-separated list (no white space)
of existing attribute types. Use this option to inform users of suggested
attributes for use with elements of the newly created type. This does not
restrict users from using other attributes. (Users can view the list with describe or lstype.)
Specify attribute-type-selector in the form [attype:]type-name[@vob-selector]
Event Records and Comments
- Default
- Creates one or more event records, with
commenting controlled by your .clearcase_profile file
(default: –cqe). See the comments reference
page. Comments can be edited with chevent.
- –c·omment comment | –cfi·le comment-file-pname |–cq·uery | –cqe·ach | –nc·omment
- Overrides the default with the option you
specify. See the comments reference page.
Naming the Element Types
- Default
- The element type is created in the VOB
that contains the current working directory unless you specify another VOB
with the @vob-selector argument.
- type-name ...
- Names of the element types to be created.
Specify element-type-selector in the form [eltype:]type-name[@vob-selector]
EXAMPLES
The UNIX examples in this section are written for use in csh. If you use another shell, you may need to use different quoting and escaping conventions.
The Windows examples that include wildcards or quoting are written for use in cleartool interactive mode. If you use cleartool single-command mode, you may need to change the wildcards and quoting to make your command interpreter process the command appropriately.
In cleartool single-command mode, cmd-context represents the UNIX shell or Windows command interpreter prompt, followed by the cleartool command. In cleartool interactive mode, cmd-context represents the interactive cleartool prompt.
- Create an element type named c_source using the predefined text_file element type as the supertype.
- Create an element type for storing binary data named bin_file, using the predefined file element type as the supertype.
- Create an element type based on the user-defined element type bin_file (from previous example) for storing executable files. Include an attribute list.
- Create a "directory of include files" element type, using the predefined directory element type as the supertype. Provide a comment on the command line.
- Change the checkin default for an existing element type so that it preserves the file modification time. Provide a comment on the command line.
- Create an element type for storing binary data named grph_file, using the predefined file element type as the supertype. Specify the merge type as never. Merge type information is applied when an element of this type is used in a UCM deliver or rebase operation.