Purpose:
|
Contains additional required file header information.
|
|
Derivation:
|
FileInfo : ACIS_OBJECT : -
|
|
Filename:
|
kern/kernel/kerndata/savres/fileinfo.hxx
|
|
Description:
|
Contains additional file header information, such as ID of the product used to save the model,
ACIS version, millimeters per model unit, date model was saved,
ACIS save file version, and other relevant model data.
|
|
|
Beginning with
ACIS Release 6.3, it is
required that the product ID and units scale be populated for the file header before you can save a SAT file, regardless of the save file version. If you do not set both of these data,
ACIS will generate an error. Refer to the
set_product_id and
set_units methods of this class.
|
|
Constructor:
|
public: FileInfo::FileInfo
();
|
|
|
C++ allocation constructor requests memory for this object but does not populate it.
|
|
|
|
|
|
|
public: FileInfo::FileInfo
(
|
|
|
FileInfo const&
|
// file name
|
|
|
);
|
|
|
C++ copy constructor requests memory for this object and populates it with the data from the object supplied as an argument.
|
|
|
|
|
Destructor:
|
public: FileInfo::~FileInfo
();
|
|
|
C++ destructor for
FileInfo which deallocates memory.
|
|
|
|
Methods:
|
public: const char* FileInfo::acis_version
() const;
|
|
|
Returns the
ACIS version number used to save the model.
|
|
|
|
|
|
|
public: const char* FileInfo::date
() const;
|
|
|
Returns the date on the save file.
|
|
|
|
|
|
|
public: int FileInfo::file_version
() const;
|
|
|
Returns the save file version used in storing the file.
|
|
|
|
|
|
|
public: FileInfo& FileInfo::operator=
(
|
|
|
FileInfo const&
|
// file name
|
|
|
);
|
|
|
Performs an assignment operation.
|
|
|
|
|
|
|
public: const char* FileInfo::product_id
() const;
|
|
|
Returns the ID of the product.
|
|
|
|
|
|
|
public: void FileInfo::reset
();
|
|
|
Resets the values to the default settings for the file information.
|
|
|
|
|
|
|
public: void FileInfo::reset_vars
();
|
|
|
Routine to reset the values for the file information to the default values.
|
|
|
|
|
|
|
public: void FileInfo::restore
();
|
|
|
Restores the file information from a save file.
|
|
|
if (restore_version_number >= FILEINFO_VERSION)
|
|
read_string
|
Product
|
|
read_string
|
ACIS Version
|
|
read_string
|
Date
|
|
read_real
|
Units
|
|
read_real
|
Tolerance, abs
|
|
|
read_real
|
|
|
Tolerance, nor
|
|
|
|
|
|
|
public: void FileInfo::save
();
|
|
|
Saves the product ID, version, time, units,
SPAresabs, and
SPAresnor.
|
|
|
|
|
|
|
public: void FileInfo::set_masked
(
|
|
|
unsigned long,
|
// number of fields
|
|
|
FileInfo const&
|
// file name
|
|
|
);
|
|
|
Copy selected fields from another instance.
|
|
|
|
|
|
|
public: void FileInfo::set_product_id
(
|
|
|
const char*
|
// ID
|
|
|
);
|
|
|
Sets the product ID. The product ID can be any string greater than 4 characters.
Spatial recommends that the string contain your product name and the product version, so that SAT files generated by your product can be easily identified.
|
|
|
Beginning with
ACIS Release 6.3, it is
required that the product ID and units scale be populated for the file header before you can save a SAT file.
|
|
|
|
|
|
|
public: void FileInfo::set_units
(
|
|
|
double
|
// number of millimeters
|
|
|
);
|
|
|
Sets the model units scale (in millimeters). Set the scale to the appropriate units for your product (1.0 indicates that 1 unit equals 1 millimeter).
|
|
|
Beginning with
ACIS Release 6.3, it is
required that the product ID and units scale be populated for the file header before you can save a SAT file.
|
|
|
|
|
|
|
public: double FileInfo::tol_abs
() const;
|
|
|
Returns the value of the
SPAresabs when the model was saved.
|
|
|
|
|
|
|
public: double FileInfo::tol_nor
() const;
|
|
|
Returns the value of the
SPAresnor when the model was saved.
|
|
|
|
|
|
|
public: double FileInfo::units
() const;
|
|
|
Returns the value of the millimeters per model unit.
|
|
|
|
|
|
|
public: void FileInfo::valid
();
|
|
|
Checks the values of the units and product id.
|