Aegis  4.25.D505
Public Types | Public Member Functions | Data Fields | Private Member Functions
change Class Reference

#include <change.h>

Public Types

typedef changepointer

Public Member Functions

nstring attributes_get (const nstring &name)
bool attributes_get_boolean (const nstring &name)
nstring brief_description_get (void)
nstring copyright_years_get_string (void)
time_t completion_timestamp (void)
string_tycreator_name (void)
string_tycstate_filename_get (void)
cstate_tycstate_get (void)
void cstate_write (void)
long delta_number_get (void)
nstring description_get (void)
string_tydeveloper_name (void)
user_ty::pointer developer_user_get (void)
bool file_exists (const nstring &filename)
fstate_src_tyfile_find (const nstring &filename, view_path_ty vp)
fstate_src_tyfile_find (fstate_src_ty *src, view_path_ty vp)
fstate_src_tyfile_find (cstate_src_ty *src, view_path_ty vp)
fstate_src_tyfile_find (const nstring &filename)
fstate_src_tyfile_find_fuzzy (const nstring &filename, view_path_ty vp)
fstate_src_tyfile_find_uuid (string_ty *uuid, view_path_ty view_path)
fstate_src_tyfile_find_uuid (const nstring &uuid, view_path_ty view_path)
fstate_src_tyfile_new (string_ty *file_name)
fstate_src_tyfile_new (fstate_src_ty *meta)
string_tyfile_path (string_ty *file_name)
nstring file_path (const nstring &file_name)
string_tyfile_path (fstate_src_ty *src)
string_tyfile_path_by_uuid (string_ty *uuid)
nstring file_path_by_uuid (const nstring &uuid)
bool file_promote (void)
string_tyfile_resolve_name (user_ty::pointer up, string_ty *file_name)
nstring file_resolve_name (user_ty::pointer up, const nstring &file_name)
void file_resolve_names (user_ty::pointer up, string_list_ty &file_names)
bool file_unchanged (fstate_src_ty *src_data, user_ty::pointer up)
bool file_is_config (string_ty *name)
bool download_files_accessable (void)
fstate_tyfstate_get (void)
int gid_get () const
nstring integration_directory_get (bool resolve)
string_tyintegrator_name (void)
bool is_a_branch (void)
bool is_awaiting_development (void)
bool is_being_developed (void)
bool is_being_integrated (void)
bool is_completed (void)
nstring pconf_attributes_find (const nstring &name)
bool pconf_attributes_get_boolean (const nstring &name, bool dflt=false)
nstring pconf_copyright_owner_get (void)
fstate_typfstate_get (void)
void project_specific_setenv_performed_set (void)
bool project_specific_setenv_performed_get () const
string_tyreviewer_name (void)
bool run_project_file_command_needed (void)
void run_project_file_command (const user_ty::pointer &up)
void run_project_file_command_done (void)
void run_new_file_command (string_list_ty *slp, const user_ty::pointer &up)
void run_new_file_undo_command (string_list_ty *slp, const user_ty::pointer &up)
void run_new_test_command (string_list_ty *slp, const user_ty::pointer &up)
void run_new_test_undo_command (string_list_ty *slp, const user_ty::pointer &up)
void run_copy_file_command (string_list_ty *slp, const user_ty::pointer &up)
void run_copy_file_undo_command (string_list_ty *slp, const user_ty::pointer &up)
void run_remove_file_command (string_list_ty *slp, const user_ty::pointer &up)
void run_remove_file_undo_command (string_list_ty *slp, const user_ty::pointer &up)
void run_make_transparent_command (string_list_ty *slp, const user_ty::pointer &up)
void run_make_transparent_undo_command (string_list_ty *slp, const user_ty::pointer &up)
void run_forced_develop_begin_notify_command (const user_ty::pointer &up)
void run_develop_end_notify_command (void)
void run_develop_end_undo_notify_command (void)
void run_review_begin_notify_command (void)
void run_review_begin_undo_notify_command (void)
void run_review_pass_notify_command (void)
void run_review_pass_undo_notify_command (void)
void run_review_fail_notify_command (void)
void run_integrate_pass_notify_command (void)
void run_integrate_fail_notify_command (void)
void run_develop_begin_early_command (user_ty::pointer up)
void run_develop_begin_command (user_ty::pointer up)
void search_path_get (string_list_ty *result, bool resolve)
void search_path_get (nstring_list &result, bool resolve)
time_t time_limit_get (void)
int umask_get () const
nstring uuid_get (void)
void uuid_get_list (nstring_list &uuids)
nstring version_debian_get (void)
nstring version_rpm_get (void)
nstring version_get (void)
bool was_a_branch (void)

Data Fields

long reference_count
projectpp
long number
cstate_tycstate_data
string_tycstate_filename
int cstate_is_a_new_file
fstate_tyfstate_data
symtab_tyfstate_stp
symtab_tyfstate_uuid_stp
string_tyfstate_filename
fstate_typfstate_data
symtab_typfstate_stp
symtab_typfstate_uuid_stp
string_typfstate_filename
int fstate_is_a_new_file
string_tytop_path_unresolved
string_tytop_path_resolved
string_tydevelopment_directory_unresolved
string_tydevelopment_directory_resolved
string_tyintegration_directory_unresolved
string_tyintegration_directory_resolved
string_tylogfile
pconf_typconf_data
long lock_magic
int bogus
string_tyarchitecture_name
string_list_tyfile_list [view_path_MAX]
bool project_specific_setenv_performed

Private Member Functions

void fimprove (fstate_ty *fstate_data)

Detailed Description

Definition at line 54 of file change.h.


Member Typedef Documentation

The pointer typedef is provided so that clients of this interface may use change::pointer everywhere they need to point at a change instance, and only this typedef needs to be edited to use a variety of smart pointer instead.

Definition at line 63 of file change.h.


Member Function Documentation

The attributes_get method is used to obtain the value of an attribute of this change set.

Parameters:
nameThe name of the attribute. Attribute names are not case sensitive.
Returns:
the string value of the attribute, or the empty string if not found.
bool change::attributes_get_boolean ( const nstring name)

The attributes_get_boolean method is used to obtain the value of an attribute of this change set, as a true/false attribute.

Parameters:
nameThe name of the attribute. Attribute names are not case sensitive.
Returns:
the boolean value of the attribute, or false if the attribute is not found or is not interpretable as a boolean.

The brief_description_get method is used to obtain the brief description of this change set.

time_t change::completion_timestamp ( void  )

The completion_timestamp method is used to obtain the time that the change set completed integration, or "now" if it is not yet complete. use the is_completed method to distinguish the two cases.

The copyright_years_get_string is used to get a string containing the list fo copyrigth years, a union of the project's copyright years and this change set's copyright years.

The creator_name method is used to obtain the Unix name of the user that created this change.

Returns:
The string value of the Unix name or NULL if not defined. DO NOT str_free it when you are done with it, it is cached.

The cstate_filename_get method is used to obtain the name of the file containing cstate meta-data of this change.

Returns:
a string. DO NOT str_free it when you are done with it, it is cached.

The cstate_get method may be used to obtain the cstate meta-data of this change.

void change::cstate_write ( void  )

THe cstate_write method may be used to write the cstate meta-data of this change

long change::delta_number_get ( void  )

The delta_number_get method is used to get the delta number of a change, or zero if the change is not yet completed.

The description_get method is used to obtain the long description of this change set.

The developer_name method is used to obtain the Unix name of the developer of this change.

Returns:
The string value of the Unix name or NULL if not defined. DO NOT str_free it when you are done with it, it is cached.

The developer_user_get method is used to obtain a user_ty instance representing the (most recent) developer of this change set.

The download_files_acessable method may be used to to determine whether or not the calling user has permission to access the change set's download files. This usually means read and search premission on the development directory and/or the integration director, unless the change set is in the completed state.

bool change::file_exists ( const nstring filename)

The file_exists method is used to determine whether or not a file exists in the change set. (view_path == view_path_first)

Parameters:
filenameThe base-relative name of the file to search for.
fstate_src_ty* change::file_find ( const nstring filename,
view_path_ty  vp 
)

The file_find method is used to locate a change file similar to the file named.

Parameters:
filenameThe name of the file to be found.
vpThe style of view path to be used.

The file_find method is used to locate a change file similar to the one indicated. If possible it uses the UUID otherwise (for backwards compatibility) it uses the file name.

Parameters:
srcThe meta-data of the file to be found.
vpThe style of view path to be used.

The file_find method is used to locate a change file similar to the one indicated. If possible it uses the UUID otherwise (for backwards compatibility) it uses the file name.

Parameters:
srcThe meta-data of the file to be found.
vpThe style of view path to be used.
fstate_src_ty* change::file_find ( const nstring filename)

The file_find method is used to locate a change file similar to the file named, in the change set itself (view_path == view_path_first).

Parameters:
filenameThe name of the file to be found.
fstate_src_ty* change::file_find_fuzzy ( const nstring filename,
view_path_ty  vp 
)

The file_find_fuzzy method is used to locate a change file with a name similar to the one given.

Parameters:
filenameThe name of the file to be found.
vpThe style of view path to be used.

The file_find_uuid method is used to find a source file given the UUID.

Parameters:
uuidThe UUID to search for.
view_pathThe style and depth of search for the file.
Returns:
a pointer to the file information, or NULL if no file has the specified UUID.
fstate_src_ty* change::file_find_uuid ( const nstring uuid,
view_path_ty  view_path 
)

The file_find_uuid method is used to find a source file given the UUID.

Parameters:
uuidThe UUID to search for.
view_pathThe style and depth of search for the file.
Returns:
a pointer to the file information, or NULL if no file has the specified UUID.

The file_is_config method is used to determine whether or not the named file is a configuration file.

Parameters:
nameThe name of the file of interest
Returns:
true if it is a config file, false if not.

The file_new method is used to add a new file to a change set's file manifest. No checking is poerformed, it is up to the caller to ensure that the name is unique.

Parameters:
file_nameThe name of the file to be created.
Returns:
A newly allocated file, with the name set, and everything else blank.

The file_new method is used to add a new file to a change set's file manifest. No checking is poerformed, it is up to the caller to ensure that the file name and UUID are unique. Typically this is used when adding a project file to a change set for modification or removal.

Parameters:
metaThe meta-data of the file to be created.
Returns:
A newly allocated file, with the name set, and everything else blank.

The file_path method is used to obtain the absolute path to the given change file.

Parameters:
file_nameThe name of the file in question.
Returns:
a string containing the absolute path, or NULL if the file is not a change source file.
nstring change::file_path ( const nstring file_name)

The file_path method is used to obtain the absolute path to the given change file.

Parameters:
file_nameThe name of the file in question.
Returns:
a string containing the absolute path, or the empty string if the file is not a change source file.

The file_path method is used to obtain the absolute path to the given change file.

Parameters:
srcThe meta-data of the file in question.
Returns:
a string containing the absolute path, or NULL if the file is not a change source file.

The file_path_by_uuid method is used to obtain the absolute path to the given change file.

Parameters:
uuidThe UUID of the file in question.
Returns:
a string containing the absolute path, or NULL if the file is not a change source file.

The file_path_by_uuid method is used to obtain the absolute path to the given change file.

Parameters:
uuidThe UUID of the file in question.
Returns:
a string containing the absolute path, or NULL if the file is not a change source file.
bool change::file_promote ( void  )

The file_promote method is used to check whether or not recent integrations have change the actions the change files must perform.

If two changes are creating the same file, the first one integrated means that the second one must update its action to "modify".

If two changes are removing the same file, the first one integrated means that the second one needs to drop the file from its list.

If one change is removing a file, and a second change is modifying the same file, after the first change is integrated, the second change must update its action to "create".

Returns:
true if anything changed, false if nothing changed.

The file_resolve_name method is used to resolve an arbitrary UNIX pathname (relative or absolute) into a base relative path within a change set's search path.

Parameters:
upThe user invoking the program.
file_nameThe file name to be resolved.
Returns:
The resolved base relative file name. Use str_free when you are done with it.
nstring change::file_resolve_name ( user_ty::pointer  up,
const nstring file_name 
)

The file_resolve_name method is used to resolve an arbitrary UNIX pathname (relative or absolute) into a base relative path within a change set's search path.

Parameters:
upThe user invoking the program.
file_nameThe file name to be resolved.
Returns:
The resolved base relative file name. Use str_free when you are done with it.

The file_resolve_names method is used to resolve arbitrary UNIX pathnames (relative or absolute) into base relative paths within a change set's search path.

Parameters:
upThe user invoking the program.
file_namesThe file names to be resolved. This parameter ISN'T const because this will be done in situ.
bool change::file_unchanged ( fstate_src_ty src_data,
user_ty::pointer  up 
)

The file_unchanged method is used to determine whether a source file is unchanged compared to the file in the baseline.

Parameters:
src_dataThe file in question.
upThe user to perform file actions as.
Returns:
bool; true if the file is unchanged, false if the file has changed, and false if the comparison isn't meaningful.
void change::fimprove ( fstate_ty fstate_data) [private]

The fimprove method is used to cope with previous versions of the file meta data, and rewrite them to conform to later expectations.

Parameters:
fstate_dataThe file meta data to be massaged.

The fstate_get method is used to obtain a current value for the change file state symbol table.

Note:
This would be static to aegis/change_file.c if only aegis/aer/value/fstate.c did not need it. No other place should access this directly.
int change::gid_get ( ) const

The gid_get method is used to obtain the Unix group id of the change owner.

The integration_directory_get method may be used to obtain the change's integration directory path. It is an error if the change is not in the 'being integrated' state.

Parameters:
resolvewhether or not to resolve symlinks in the path.

The integrator_name method is used to obtain the Unix group name of the integrator.

Returns:
The string value of the Unix name or NULL if not defined. DO NOT str_free it when you are done with it, it is cached.
bool change::is_a_branch ( void  )

The is_a_branch method is used to determine whether or not this change set is an active branch. If you want to know if it was ever an active branch (e.g. now completed) use the was_a_branch method.

The is_awaiting_development method returns true if the given change is in the awaiting development state, and false if it is not.

bool change::is_being_developed ( void  )

The is_being_developed method returns true if the given change is in the being developed state, and false if it is not.

bool change::is_being_integrated ( void  )

The is_being_integrated method is used to determine whether or not this is in the being integrated state.

Returns:
bool; true if this is in the being integrated state, and false if it is not.
bool change::is_completed ( void  )

The change_is_completed function returns true (non-zero) if this change is in the completed state, and false (zero) if it is not.

The pconf_attributes_get method is used to obtain the value of an attribute of the project, from the project configuration file. It could be in this change, or it could be in a baseline or an ancestor baseline.

Parameters:
nameThe name of the attribute. Attribute names are not case sensitive.
Returns:
the string value of the attribute, or the empty string if not found.
bool change::pconf_attributes_get_boolean ( const nstring name,
bool  dflt = false 
)

The pconf_attributes_get_boolean method is used to obtain the value of an attribute of the project, from the project configuration file. It could be in this change, or it could be in a baseline or an ancestor baseline.

Parameters:
nameThe name of the attribute. Attribute names are not case sensitive.
dfltThe default value to return if no attribute available.
Returns:
the string value of the attribute, or the empty string if not found.

The pconf_copyright_owner_get method is used to obtain the name of the copyright holder of a project.

The pfstate_get method is used to obtain the project file state information for a change set. This is all of the project files, not just one.

The project_specific_setenv_performed_get method is used to know if the environment variable(s), specified as project_specific attributes, has been already exported.

Returns:
True if the variables has been already exported, false otherwise.

The project_specific_setenv_performed_set method is used to remember if the environment variable(s), specified as project_specific attributes, has been already exported.

Returns:
Void.

The reviewer_name method is used to determine the Unix name of the (last) reviewer.

Returns:
The string representation of the Unix name or NULL if not defined. DO NOT str_free it when you are done with it, it is cached.

The run_copy_file_command method is used to run the command in the copy_file_command field of the aegis.conf file.

Parameters:
slpThe list of filenames affected.
upthe user to run the program as

The run_copy_file_undo_command method is used to run the command in the copy_file_undo_command field of the aegis.conf file.

Parameters:
slpThe list of filenames affected.
upthe user to run the program as

The run_develop_begin_command method is used to run the develop_begin_command from the projetc configuration file. This is used by the aedb command, just all other actions performed by aedb.

Parameters:
upThe user to run the command as.

The run_develop_begin_early_command method is used to run the develop_begin_early_command from the project configuration file. This is used by the aedb command, just after the development directory has been created.

Parameters:
upThe user to run the command as.

The run_develop_end_notify_command method is used to run the command in the develop_end_notify_command field of the aegis.conf file.

The run_develop_end_undo_notify_command method is used to run the command in the develop_end_undo_notify_command field of the aegis.conf file.

The run_forced_develop_begin_notify_command method is used to run the command in the forced_develop_begin_notify_command field of the aegis.conf file.

Parameters:
upthe user to run the program as

The run_integrate_fail_notify_command method is used to run the command in the integrate_fail_notify_command field of the aegis.conf file.

The run_integrate_pass_notify_command method is used to run the command in the integrate_pass_notify_command field of the aegis.conf file.

The run_make_transparent_command method is used to run the command in the make_transparent_command field of the aegis.conf file.

Parameters:
slpThe list of filenames affected.
upthe user to run the program as

The run_make_transparent_undo_comman method is used to run the command in the make_transparent_undo_command field of the aegis.conf file.

Parameters:
slpThe list of filenames affected.
upthe user to run the program as

The run_new_file_command method is used to run the new_file_command field of the aegis.conf file.

Parameters:
slpThe list of new file names
upTh euser to run the command as.

The run_new_file_undo_command method is used to run the command in the new_file_undo_command field of the aegis.conf file.

Parameters:
slpThe list of filenames affected.
upthe user to run the program as

The run_new_test_command method is used to run the command in the new_test_command field of the aegis.conf file.

Parameters:
slpThe list of filenames affected.
upthe user to run the program as

The run_new_test_undo_command method is used to run the command in the new_test_undo_command field of the aegis.conf file.

Parameters:
slpThe list of filenames affected.
upthe user to run the program as

The run_project_file_command method is used to run the command configured in the aegis.conf file's project_file_command field.

Parameters:
upThe user to run the command as.
Note:
this method MUST be called outside the change set lock

The run_project_file_command_done method is used to remember that the project_file comman has been (is about to be) called recently.

Note:
this method MUST be called INSIDE the change set lock

The run_project_file_command_needed method may be used to determine whether or not the project_file_command needstosed in recent integration history.

Returns:
true if need to run it (see next method), false if not.

The run_remove_file_command method is used to run the command in the remove_file_command field of the aegis.conf file.

Parameters:
slpThe list of filenames affected.
upthe user to run the program as

The run_remove_file_undo_command method is used to run the command in the remove_file_undo_command field of the aegis.conf file.

Parameters:
slpThe list of filenames affected.
upthe user to run the program as

The run_review_begin_notify_command method is used to run the command in the review_begin_notify_command field of the aegis.conf file.

The run_review_begin_undo_notify_command method is used to run the command in the review_begin_undo_notify_command field of the aegis.conf file.

The run_review_fail_notify_command method is used to run the command in the review_fail_notify_command field of the aegis.conf file.

The run_review_pass_notify_command method is used to run the command in the review_pass_notify_command field of the aegis.conf file.

The run_review_pass_undo_notify_command method is used to run the command in the review_pass_undo_notify_command field of the aegis.conf file.

void change::search_path_get ( string_list_ty result,
bool  resolve 
)

The search_path_get method may be used to obtain the search path (list of progressively more out-of-date ancestor branches) within which to search for files.

Parameters:
resultWhere to append the additional directories.
resolveWhether or not to expand synbolic links within paths.
void change::search_path_get ( nstring_list result,
bool  resolve 
)

The search_path_get method may be used to obtain the search path (list of progressively more out-of-date ancestor branches) within which to search for files.

Parameters:
resultWhere to append the additional directories.
resolveWhether or not to expand synbolic links within paths.
time_t change::time_limit_get ( void  )
int change::umask_get ( ) const

The umask method is used to obtain the umask for this change.

Returns:
An int representing the umask value.

The uuid_get method is used to obtain the UUID of this change set.

Returns:
The uuid of the change set, or the empty string of this change set doesn't have a UUID.

The uuid_get_list method is used to obtain all of the UUIDs associated with this change set. This includes the change set's UUID, if it has one, and all of the aoriginal-uuid attributes.

Parameters:
uuidsWhere to put all of the UUIDs associated with this change set.

The version_debian_get method is used to get the version of this change set, in Debian format. In particular, it makes being-developed change sets look like they are "release candidates" for the next project delta, otherwise business as usual.

The version_get method is used to get the version of this change set. This will consist of the branch name (1.2) combined with ether a delta number (.D123) or, for incomplete changes, a change number (.C123).

The version_rpm_get method is used to get the version of this change set, in RPM format. In particular, it makes being-developed change sets look like they are "branched from" for the current project delta, otherwise business as usual.

bool change::was_a_branch ( void  )

The was_a_branch method is used to determine whether or not this change set is, or was ever, an active branch. If you want to know if it is a currently active branch (beging_developed) use the is_a_branch method.


Field Documentation

Definition at line 90 of file change.h.

Definition at line 89 of file change.h.

Definition at line 68 of file change.h.

Definition at line 69 of file change.h.

Definition at line 70 of file change.h.

Definition at line 83 of file change.h.

Definition at line 82 of file change.h.

Definition at line 91 of file change.h.

Definition at line 71 of file change.h.

Definition at line 74 of file change.h.

Definition at line 79 of file change.h.

Definition at line 72 of file change.h.

Definition at line 73 of file change.h.

Definition at line 85 of file change.h.

Definition at line 84 of file change.h.

Definition at line 88 of file change.h.

Definition at line 86 of file change.h.

Definition at line 67 of file change.h.

Definition at line 87 of file change.h.

Definition at line 75 of file change.h.

Definition at line 78 of file change.h.

Definition at line 76 of file change.h.

Definition at line 77 of file change.h.

Definition at line 66 of file change.h.

Definition at line 92 of file change.h.

Definition at line 65 of file change.h.

Definition at line 81 of file change.h.

Definition at line 80 of file change.h.


The documentation for this class was generated from the following file: