Synopsis
char *OMret_obj_path_to (
OMobj_id object_id,
OMobj_id upto_object_id,
char *object_name_buffer,
int buffer_size );
Description
OMret_obj_path_to returns the pathname of an object, qualified up to a specified object.
Arguments
object_id
The object id.
upto_object_id
The id of the object up to which the pathname of object_id should be qualified. If upto_object_id is not in object_id 's path, the routine returns object_id 's full pathname.
object_name_buffer
The address of a character buffer in which to store the pathname. If you pass a NULL buffer, OMret_obj_path_to ignores the buffer_size argument and returns a malloced string. You should free the string when you're done with it by using free().
buffer_size
The size of the buffer, in bytes. OMret_obj_path_to returns at maximum this many bytes. Names are truncated from the start of the pathname and ellipses are inserted when this limit is reached.
mode
0 is the default
OM_PATH_NO_VAL changes how "name" objects are displayed
OM_PATH_DERIVED_OBJ checks to see if the "stop" object is derived from the object's parent and stops in that case; this is generally not needed.
OM_PATH_USER_NAME use the "user_name" property if it is set on the object instead of the regular name. This is probably the only one you might care about
Returned value
A character string containing the object's unqualified name.
On failure, OMret_obj_path_to returns the string "<invalid>" or "<null>."