still cleaning

This commit is contained in:
The Coriolis Project 2008-04-09 17:14:17 +00:00
parent 51dd2b29b3
commit acdaa2e4f5
17 changed files with 43 additions and 43 deletions

View File

@ -48,7 +48,7 @@ Cell::Cell(Library* library, const Name& name)
if (!_library) if (!_library)
throw Error("Can't create " + _TName("Cell") + " : null library"); throw Error("Can't create " + _TName("Cell") + " : null library");
if (name.IsEmpty()) if (name.isEmpty())
throw Error("Can't create " + _TName("Cell") + " : empty name"); throw Error("Can't create " + _TName("Cell") + " : empty name");
if (_library->getCell(_name)) if (_library->getCell(_name))
@ -103,7 +103,7 @@ void Cell::setName(const Name& name)
// ********************************* // *********************************
{ {
if (name != _name) { if (name != _name) {
if (name.IsEmpty()) if (name.isEmpty())
throw Error("Can't change " + _TName("Cell") + " name : empty name"); throw Error("Can't change " + _TName("Cell") + " name : empty name");
if (_library->getCell(name)) if (_library->getCell(name))

View File

@ -23,7 +23,7 @@ DRCError::DRCError(Cell* cell, const Name& name, const Box& boundingBox)
_name(name), _name(name),
_boundingBox(boundingBox) _boundingBox(boundingBox)
{ {
if (_name.IsEmpty()) if (_name.isEmpty())
throw Error("Can't create " + _TName("DRCError") + " : empty name"); throw Error("Can't create " + _TName("DRCError") + " : empty name");
if (_boundingBox.isEmpty()) if (_boundingBox.isEmpty())

View File

@ -81,7 +81,7 @@ Record* Entity::_getRecord() const
Record* record = Inherit::_getRecord(); Record* record = Inherit::_getRecord();
if (record) { if (record) {
Occurrence occurrence = Occurrence(this); Occurrence occurrence = Occurrence(this);
if (occurrence.HasProperty()) if (occurrence.hasProperty())
record->Add(getSlot("Occurrence", occurrence)); record->Add(getSlot("Occurrence", occurrence));
} }
return record; return record;

View File

@ -25,19 +25,19 @@ Go::Go()
{ {
} }
bool Go::AutoMaterializationIsDisabled() bool Go::autoMaterializationIsDisabled()
// ************************************* // *************************************
{ {
return !AUTO_MATERIALIZATION_IS_ENABLED; return !AUTO_MATERIALIZATION_IS_ENABLED;
} }
void Go::EnableAutoMaterialization() void Go::enableAutoMaterialization()
// ********************************* // *********************************
{ {
AUTO_MATERIALIZATION_IS_ENABLED = true; AUTO_MATERIALIZATION_IS_ENABLED = true;
} }
void Go::DisableAutoMaterialization() void Go::disableAutoMaterialization()
// ********************************** // **********************************
{ {
AUTO_MATERIALIZATION_IS_ENABLED = false; AUTO_MATERIALIZATION_IS_ENABLED = false;
@ -48,7 +48,7 @@ void Go::_postCreate()
{ {
Inherit::_postCreate(); Inherit::_postCreate();
if (!AutoMaterializationIsDisabled()) materialize(); // materialized after entire post creation if (!autoMaterializationIsDisabled()) materialize(); // materialized after entire post creation
} }
void Go::_preDestroy() void Go::_preDestroy()

View File

@ -47,15 +47,15 @@ class Go : public Entity {
// Predicates // Predicates
// ********** // **********
public: static bool AutoMaterializationIsDisabled(); public: static bool autoMaterializationIsDisabled();
public: bool isMaterialized() const {return (_quadTree != NULL);}; public: bool isMaterialized() const {return (_quadTree != NULL);};
// Updators // Updators
// ******** // ********
public: static void EnableAutoMaterialization(); public: static void enableAutoMaterialization();
public: static void DisableAutoMaterialization(); public: static void disableAutoMaterialization();
public: virtual void materialize() = 0; public: virtual void materialize() = 0;
public: virtual void unmaterialize() = 0; public: virtual void unmaterialize() = 0;

View File

@ -169,7 +169,7 @@ Instance::Instance(Cell* cell, const Name& name, Cell* masterCell, const Transfo
if (!_cell) if (!_cell)
throw Error("Can't create " + _TName("Instance") + " : null cell"); throw Error("Can't create " + _TName("Instance") + " : null cell");
if (name.IsEmpty()) if (name.isEmpty())
throw Error("Can't create " + _TName("Instance") + " : empty name"); throw Error("Can't create " + _TName("Instance") + " : empty name");
if (_cell->getInstance(_name)) if (_cell->getInstance(_name))
@ -339,7 +339,7 @@ void Instance::setName(const Name& name)
// ************************************* // *************************************
{ {
if (name != _name) { if (name != _name) {
if (name.IsEmpty()) if (name.isEmpty())
throw Error("Can't change instance name : empty name"); throw Error("Can't change instance name : empty name");
if (_cell->getInstance(name)) if (_cell->getInstance(name))

View File

@ -31,7 +31,7 @@ Layer::Layer(Technology* technology, const Name& name, const Unit& minimalSize,
if (!_technology) if (!_technology)
throw Error("Can't create " + _TName("Layer") + " : null technology"); throw Error("Can't create " + _TName("Layer") + " : null technology");
if (_name.IsEmpty()) if (_name.isEmpty())
throw Error("Can't create " + _TName("Layer") + " : empty name"); throw Error("Can't create " + _TName("Layer") + " : empty name");
if (_technology->getLayer(_name)) if (_technology->getLayer(_name))
@ -54,7 +54,7 @@ void Layer::setName(const Name& name)
// ********************************** // **********************************
{ {
if (name != _name) { if (name != _name) {
if (name.IsEmpty()) if (name.isEmpty())
throw Error("Can't change layer name : empty name"); throw Error("Can't change layer name : empty name");
if (_technology->getLayer(name)) if (_technology->getLayer(name))

View File

@ -31,7 +31,7 @@ Library::Library(DataBase* dataBase, Library* library, const Name& name)
if (!_dataBase) if (!_dataBase)
throw Error("Can't create " + _TName("Library") + " : null data base"); throw Error("Can't create " + _TName("Library") + " : null data base");
if (name.IsEmpty()) if (name.isEmpty())
throw Error("Can't create " + _TName("Library") + " : empty name"); throw Error("Can't create " + _TName("Library") + " : empty name");
if (!_library) { if (!_library) {
@ -71,7 +71,7 @@ void Library::SetName(const Name& name)
// ************************************ // ************************************
{ {
if (name != _name) { if (name != _name) {
if (name.IsEmpty()) if (name.isEmpty())
throw Error("Can't change library name : empty name"); throw Error("Can't change library name : empty name");
if (_library && _library->getLibrary(name)) if (_library && _library->getLibrary(name))

View File

@ -148,7 +148,7 @@ char Name::operator[](unsigned index) const
return _sharedName->_string[index]; return _sharedName->_string[index];
} }
bool Name::IsEmpty() const bool Name::isEmpty() const
// *********************** // ***********************
{ {
return _sharedName->_string.empty(); return _sharedName->_string.empty();

View File

@ -60,7 +60,7 @@ class Name {
// Predicates // Predicates
// ********** // **********
public: bool IsEmpty() const; public: bool isEmpty() const;
// Others // Others
// ****** // ******

View File

@ -254,7 +254,7 @@ Net::Net(Cell* cell, const Name& name)
if (!_cell) if (!_cell)
throw Error("Can't create " + _TName("Net") + " : null cell"); throw Error("Can't create " + _TName("Net") + " : null cell");
if (name.IsEmpty()) if (name.isEmpty())
throw Error("Can't create " + _TName("Net") + " : empty name"); throw Error("Can't create " + _TName("Net") + " : empty name");
if (_cell->getNet(_name)) if (_cell->getNet(_name))
@ -414,7 +414,7 @@ void Net::setName(const Name& name)
// ******************************** // ********************************
{ {
if (name != _name) { if (name != _name) {
if (name.IsEmpty()) if (name.isEmpty())
throw Error("Can't change net name : empty name"); throw Error("Can't change net name : empty name");
if (_cell->getNet(name)) if (_cell->getNet(name))

View File

@ -121,20 +121,20 @@ Box Occurrence::getBoundingBox() const
return _sharedPath->getTransformation().getBox(_entity->getBoundingBox()); return _sharedPath->getTransformation().getBox(_entity->getBoundingBox());
} }
bool Occurrence::HasProperty() const bool Occurrence::hasProperty() const
// ******************************** // ********************************
{ {
return (_getQuark() != NULL); return (_getQuark() != NULL);
} }
void Occurrence::MakeInvalid() void Occurrence::makeInvalid()
// ************************** // **************************
{ {
_entity = NULL; _entity = NULL;
_sharedPath = NULL; _sharedPath = NULL;
} }
void Occurrence::Put(Property* property) void Occurrence::put(Property* property)
// ************************************ // ************************************
{ {
if (!_entity) if (!_entity)
@ -148,7 +148,7 @@ void Occurrence::Put(Property* property)
quark->put(property); quark->put(property);
} }
void Occurrence::Remove(Property* property) void Occurrence::remove(Property* property)
// *************************************** // ***************************************
{ {
if (!_entity) if (!_entity)
@ -161,7 +161,7 @@ void Occurrence::Remove(Property* property)
if (quark) quark->remove(property); if (quark) quark->remove(property);
} }
void Occurrence::RemoveProperty(const Name& name) void Occurrence::removeProperty(const Name& name)
// ********************************************* // *********************************************
{ {
if (!_entity) if (!_entity)
@ -171,7 +171,7 @@ void Occurrence::RemoveProperty(const Name& name)
if (quark) quark->removeProperty(name); if (quark) quark->removeProperty(name);
} }
void Occurrence::ClearProperties() void Occurrence::clearProperties()
// ****************************** // ******************************
{ {
Quark* quark = _getQuark(); Quark* quark = _getQuark();

View File

@ -64,16 +64,16 @@ class Occurrence {
// ********** // **********
public: bool isValid() const {return (_entity != NULL);}; public: bool isValid() const {return (_entity != NULL);};
public: bool HasProperty() const; public: bool hasProperty() const;
// Updators // Updators
// ******** // ********
public: void MakeInvalid(); public: void makeInvalid();
public: void Put(Property* property); public: void put(Property* property);
public: void Remove(Property* property); public: void remove(Property* property);
public: void RemoveProperty(const Name& name); public: void removeProperty(const Name& name);
public: void ClearProperties(); public: void clearProperties();
// Others // Others
// ****** // ******

View File

@ -32,7 +32,7 @@ Reference::Reference(Cell* cell, const Name& name, Unit x, Unit y)
{ {
if ( !_extend ) _extend = getUnit(0.5); if ( !_extend ) _extend = getUnit(0.5);
if (_name.IsEmpty()) if (_name.isEmpty())
throw Error("Can't create " + _TName("Reference") + " : empty name"); throw Error("Can't create " + _TName("Reference") + " : empty name");
} }

View File

@ -104,7 +104,7 @@ Technology::Technology(DataBase* dataBase, const Name& name)
if (_dataBase->getTechnology()) if (_dataBase->getTechnology())
throw Error("Can't create " + _TName("Technology") + " : already exists"); throw Error("Can't create " + _TName("Technology") + " : already exists");
if (_name.IsEmpty()) if (_name.isEmpty())
throw Error("Can't create " + _TName("Technology") + " : empty name"); throw Error("Can't create " + _TName("Technology") + " : empty name");
} }
@ -156,7 +156,7 @@ void Technology::SetName(const Name& name)
// *************************************** // ***************************************
{ {
if (name != _name) { if (name != _name) {
if (name.IsEmpty()) if (name.isEmpty())
throw Error("Can't change technology name : empty name"); throw Error("Can't change technology name : empty name");
_name = name; _name = name;

View File

@ -75,11 +75,11 @@ extern "C" {
//DirectGetBoolAttribute(PyName_IsEmpty,IsEmpty,PyName,Name) //DirectGetBoolAttribute(PyName_IsEmpty,IsEmpty,PyName,Name)
static PyObject* PyName_IsEmpty ( PyName *self ) { static PyObject* PyName_isEmpty ( PyName *self ) {
trace << "PyName_IsEmpty()" << endl; trace << "PyName_isEmpty()" << endl;
METHOD_HEAD ( "Name.IsEmpty()" ) METHOD_HEAD ( "Name.isEmpty()" )
return ( Py_BuildValue ("i",_object->IsEmpty()) ); return ( Py_BuildValue ("i",_object->isEmpty()) );
} }
@ -93,7 +93,7 @@ extern "C" {
// PyName Attribute Method table. // PyName Attribute Method table.
PyMethodDef PyName_Methods[] = PyMethodDef PyName_Methods[] =
{ { "IsEmpty" , (PyCFunction)PyName_IsEmpty , METH_NOARGS , "True if empty." } { { "isEmpty" , (PyCFunction)PyName_isEmpty , METH_NOARGS , "True if empty." }
, { "destroy" , (PyCFunction)PyName_destroy , METH_NOARGS , { "destroy" , (PyCFunction)PyName_destroy , METH_NOARGS
, "Destroy associated hurricane object The python object remains." } , "Destroy associated hurricane object The python object remains." }
, {NULL, NULL, 0, NULL} /* sentinel */ , {NULL, NULL, 0, NULL} /* sentinel */

View File

@ -86,7 +86,7 @@ extern "C" {
// Standart Predicates (Attributes). // Standart Predicates (Attributes).
DirectGetBoolAttribute(PyOccurrence_isValid ,isValid ,PyOccurrence,Occurrence) DirectGetBoolAttribute(PyOccurrence_isValid ,isValid ,PyOccurrence,Occurrence)
DirectGetBoolAttribute(PyOccurrence_HasProperty,HasProperty,PyOccurrence,Occurrence) DirectGetBoolAttribute(PyOccurrence_hasProperty,hasProperty,PyOccurrence,Occurrence)
// Standart destroy (Attribute). // Standart destroy (Attribute).
@ -227,7 +227,7 @@ extern "C" {
, { "getMasterCell" , (PyCFunction)PyOccurrence_getMasterCell , METH_NOARGS, "Returns the cell owning the referenced entity." } , { "getMasterCell" , (PyCFunction)PyOccurrence_getMasterCell , METH_NOARGS, "Returns the cell owning the referenced entity." }
, { "getBoundingBox", (PyCFunction)PyOccurrence_getBoundingBox, METH_NOARGS, "Returns the occurrence bounding box." } , { "getBoundingBox", (PyCFunction)PyOccurrence_getBoundingBox, METH_NOARGS, "Returns the occurrence bounding box." }
, { "isValid" , (PyCFunction)PyOccurrence_isValid , METH_NOARGS, "Returns true if the occurrence is valid." } , { "isValid" , (PyCFunction)PyOccurrence_isValid , METH_NOARGS, "Returns true if the occurrence is valid." }
, { "HasProperty" , (PyCFunction)PyOccurrence_HasProperty , METH_NOARGS, "Returns true if the occurrence owns some properties." } , { "hasProperty" , (PyCFunction)PyOccurrence_hasProperty , METH_NOARGS, "Returns true if the occurrence owns some properties." }
, { "destroy" , (PyCFunction)PyOccurrence_destroy , METH_NOARGS , { "destroy" , (PyCFunction)PyOccurrence_destroy , METH_NOARGS
, "Destroy associated hurricane object, the python object remains." } , "Destroy associated hurricane object, the python object remains." }
, {NULL, NULL, 0, NULL} /* sentinel */ , {NULL, NULL, 0, NULL} /* sentinel */