Extension to the SCC API
Status determination by version number
PowerBuilder provides third-party SCC providers with an extension
to the SCC API that allows them to enhance the integration of their
products with PowerBuilder. Typically, calls to the SccDiff method
are required to determine if an object is out of sync with the SCC
repository. (This is not appropriate for Perforce or ClearCase.)
However, SCC providers can implement SccQueryInfoEx as
a primary file comparison method instead of SccDiff.
The SccQueryInfoEx method returns the most recent
version number for each object requested. This allows PowerBuilder
to compare the version number associated with the object in the PBL with the version number of the
tip revision in the SCC repository in order to determine whether
an object is in sync.
Since SccQueryInfoEx is a much simpler
request than SccDiff, the performance of the
PowerBuilder IDE improves noticeably when this feature is implemented
by the SCC provider. For these providers, the SccDiff call
is used as a backup strategy only when a version number is not returned
on an object in the repository. Also for these providers, the version
number for registered files can be displayed in the Library painter.
For more information on viewing the version number, see “Controlling columns that
display in the List view”.
Once the new API method is implemented in an SCC provider
DLL and exported, PowerBuilder automatically begins to use the SCCQueryInfoEx call with
that provider. The SccQueryInfoEx method is currently
used by PBNative.
Overriding the version number
For source control systems that support the SccQueryInfoEx method,
you can manually override the version number of local files, but
only for PowerScript objects, and only when you are connected to
source control.
This can be useful with source control systems that allow
you to check out a version of an object that is not the tip revision.
However, the source control system alone decides the version number
of the tip revision when you check a file back into source control.
It is the version returned by the source control system that gets
added to the PBC file for the workspace and to the PBLs in the local directory.
For more information about the PBC file, see “Working in offline mode”.
You change the local version number for a source-controlled
PowerScript object in its Properties dialog box, which you access
from the object’s pop–up menu in the System Tree
or the Library painter. If the source control system for the workspace
supports the SccQueryInfoEx method and you are
connected to source control, the Properties dialog box for a source-controlled
PowerScript object (other than a PBT) has an editable SCC Version
text box. The SCC Version text box is grayed if the source control
system does not support the SccQueryInfoEx method
or if you are not connected to source control.
Local change only
The version number that you manually enter for an object is
discarded on check-in. Only the source control provider decides
what number the tip revision is assigned.