int kdms_create_attribute(
kobject object,
char *segment,
char *attribute,
int numargs,
int argsize,
int datatype,
int permanent,
int shared)
none
The attribute acts as storage for multiple argument values. Each attribute argument can be of any size or data type. The number of arguments, the argument size, and the data type are all specified here.
The attributes can be either created on the main object (object-level) or created on any of the object's data segments (segment-level). Whether the attribute is created at the object-level or at the segment-level is determined by the segment argument. If the segment argument is NULL, then the attribute will be instantiated at the object-level. Otherwise, the attribute will be instantiated on the specified segment, if it exists. If an attribute with the same name and scope already exists, then this function will fail.
The attribute can be either permanent or transient. Permanent impiles that when the object is closed, a representation of the attribute will be written out to the disk.
In addition to being created either at the object or segment level, the attribute can also be created at the physical or presentation level.
Changes to physical level attributes are visible to all references of the data object and are termed as "shared" attributes. Changes to presentation level attributes are visible only to the reference object on which the change was made, and thus the attribute is termed as "unshared". Since all references may have potentially different values, unshared attributes may not be permanent.
An initial value must be provided. This initial value must consist of the proper number of arguments where each argument is of the same size and data type specified in this call.
The attribute can be destroyed with the kdms_destroy_attribute function.
none
none
$DATASERV/objects/library/kdataman/src/attributes.c