#include <TeGeneralizedProxMatrix.h>
createProximityMatrix.cpp, and proxMatrixAndSpatialStatistics.cpp.
Definition at line 40 of file TeGeneralizedProxMatrix.h.
ChangeStrategies Methods for changing current strategies | |
| change current strategies | |
| TeProxMatrixConstructionParams * | getConstructionParams () |
| Get current construction params. | |
| TeProxMatrixSlicingParams * | getSlicingParams () |
| Get current slicing params. | |
| TeProxMatrixWeightsParams * | getWeightsParams () |
| Get current weights params. | |
| bool | setCurrentConstructionStrategy (TeProxMatrixConstructionStrategy< Set > *sc) |
| Set current construction strategy. | |
| bool | setCurrentSlicingStrategy (TeProxMatrixSlicingStrategy *ss) |
| Set current slicing strategy. | |
| bool | setCurrentWeightsStrategy (TeProxMatrixWeightsStrategy *sw) |
| Set current weights strategy. | |
getNeighbours Methods for return the neighbours | |
| All methods return the neighbours of a given object in a given slice.
The default is the first slice. Slices are defined according to the Slicing Strategy in use (e.g., according to distance zones, corresponding to neighbourhood orders, weights intervals, etc.). If the parameter slice is not provided, the first slice is returned. The operator[] method should preferably be used For each object, all the connection attributes are stored as properties (weight is the first). | |
| TeNeighboursMap | getMapNeighbours (const string &object_id, int slice=1) |
| Return the neighbours of an object in a slice, packed in a TeNeighboursMap. | |
| TeNeighbours | getNeighbours (const string &object_id, int slice=1) |
| Return the neighbours of an object in a slice, packed in a TeNeighbours. | |
| TeSTElementSet | getSTENeighbours (const string &object_id) |
| Return the neighbours of an object and their attributes in a spatial temporal element set (TeSTElementSet). | |
| TeNeighbours | operator[] (const string &object_id) |
| Operator [], return the neighbours packed in a TeNeighbours. | |
Public Member Functions | |
| bool | clearImplementation () |
| bool | connectObjects (const string &object_id1, const string &object_id2) |
| Connect two objects. | |
| bool | connectObjects (const string &object_id1, const string &object_id2, const TeProxMatrixAttributes &attr) |
| Connect two objects. | |
| bool | constructMatrix () |
| Reconstruct matrix and recompute weights and slicing, accornding to current strategies. | |
| bool | disconnectObjects (const string &object_id1, const string &object_id2) |
| Disconnect two objects. | |
| bool | getConnectionAttributes (const string &object_id1, string &object_id2, TeProxMatrixAttributes &attr) |
| Get connection attributes. | |
| bool | isConnected (const string &object_id1, const string &object_id2) |
| Verify if two objects are connected. | |
| int | numberOfObjects () |
| Return the number of objects. | |
| int | numerOfSlices () |
| Return the number of slices. | |
| TeGeneralizedProxMatrix & | operator= (const TeGeneralizedProxMatrix &p) |
| Attribution Operator. | |
| bool | operator== (const TeGeneralizedProxMatrix &p) const |
| Comparison Operator. | |
| bool | recomputeSlicing () |
| Sets the slicing strategy for neighbours selection. | |
| bool | recomputeWeights () |
| Recomputes the weigths, given a new strategy. The matrix is not reconstructed. | |
| bool | removeObject (const string &object_id) |
| Remove object. | |
| bool | saveGALFile (const string &name, vector< string > *ids) |
| Save the matrix in a text file. | |
| bool | saveGALFile (const string &name, map< string, string > *ids=0) |
| Save the matrix in a text file. | |
| bool | saveGWTFile (const string &name, vector< string > *ids) |
| Save the matrix in a text file. | |
| bool | saveGWTFile (const string &name, map< string, string > *ids=0) |
| Save the matrix in a text file. | |
| bool | saveTextFile (const string &name, vector< string > *ids) |
| Save the matrix in a text file. | |
| bool | saveTextFile (const string &name, map< string, string > *ids=0) |
| Save the matrix in a text file. | |
| TeGeneralizedProxMatrix (const TeGeneralizedProxMatrix &p) | |
| Copy constructor. | |
| TeGeneralizedProxMatrix (TeSTElementSet *objects, TeGeomRep geom_type, const TeGPMImplementation &type=TeGraphBreymann) | |
| Constructor based on default strategies: (a) Local adjacency of first order; (b) No siling; and (c) No weighs (all equal to 1). | |
| TeGeneralizedProxMatrix (TeProxMatrixConstructionStrategy< Set > *sc, TeProxMatrixWeightsStrategy *sw=0, TeProxMatrixSlicingStrategy *ss=0, const TeGPMImplementation &type=TeGraphBreymann, const int &gpmId=-1, const bool &isDefault=false, const string &neigsTable="", const int &slices=1) | |
| Constructor parametrized with specific strategies. Each stragegy must be previously created and correctly parametrized. | |
| TeGeneralizedProxMatrix (const int &id, const string &tableName, TeProxMatrixImplementation *imp, TeProxMatrixWeightsStrategy *ws) | |
| Constructor. | |
| TeGeneralizedProxMatrix () | |
| Empty constructor. | |
| virtual | ~TeGeneralizedProxMatrix () |
| Destructor. | |
Data Fields | |
| int | gpm_id_ |
| TeGPMImplementation | impl_strategy_ |
| bool | is_default_ |
| string | neighbourhood_table_ |
| int | total_slices_ |
Protected Member Functions | |
| TeProxMatrixImplementation * | getImplementation (const TeGPMImplementation &implementation_type=TeGraphBreymann) |
| Get the implementation from a concrete factory defined by impl_type. | |
| bool | isValid () const |
| Verify if a matrix was created correctly by the constructors. | |
Private Attributes | |
| TeProxMatrixImplementation * | imp_ |
| TeProxMatrixConstructionStrategy < Set > * | sc_ |
| TeProxMatrixSlicingStrategy * | ss_ |
| TeProxMatrixWeightsStrategy * | sw_ |
| TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix | ( | ) | [inline] |
Definition at line 63 of file TeGeneralizedProxMatrix.h.
00063 : 00064 imp_(0), sc_(0), ss_(0), sw_(0), gpm_id_(-1), 00065 is_default_(false), total_slices_(1), neighbourhood_table_(""), 00066 impl_strategy_(TeGraphBreymann) 00067 {}
| TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix | ( | const int & | id, | |
| const string & | tableName, | |||
| TeProxMatrixImplementation * | imp, | |||
| TeProxMatrixWeightsStrategy * | ws | |||
| ) | [inline] |
Definition at line 70 of file TeGeneralizedProxMatrix.h.
00070 : 00071 imp_(imp), sc_(0), ss_(0), sw_(ws), 00072 gpm_id_(id), is_default_(false), total_slices_(1), 00073 neighbourhood_table_(tableName), impl_strategy_(TeGraphBreymann) 00074 {}
| TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix | ( | TeProxMatrixConstructionStrategy< Set > * | sc, | |
| TeProxMatrixWeightsStrategy * | sw = 0, |
|||
| TeProxMatrixSlicingStrategy * | ss = 0, |
|||
| const TeGPMImplementation & | type = TeGraphBreymann, |
|||
| const int & | gpmId = -1, |
|||
| const bool & | isDefault = false, |
|||
| const string & | neigsTable = "", |
|||
| const int & | slices = 1 | |||
| ) | [inline] |
Definition at line 244 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::getImplementation(), TeGeneralizedProxMatrix< Set >::imp_, TeGeneralizedProxMatrix< Set >::ss_, and TeGeneralizedProxMatrix< Set >::sw_.
00246 : 00247 sc_(sc), 00248 ss_(ss), 00249 sw_(sw), 00250 gpm_id_(gpmId), 00251 is_default_(isDefault), 00252 total_slices_(slices), 00253 neighbourhood_table_(neigsTable), 00254 impl_strategy_(type) 00255 00256 { 00257 00258 imp_ = 0; 00259 imp_ = getImplementation(type); 00260 00261 if(!ss) 00262 ss_ = new TeProxMatrixNoSlicingStrategy(); 00263 00264 if(!sw) 00265 sw_ = new TeProxMatrixNoWeightsStrategy(); 00266 }
| TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix | ( | TeSTElementSet * | objects, | |
| TeGeomRep | geom_type, | |||
| const TeGPMImplementation & | type = TeGraphBreymann | |||
| ) | [inline] |
Definition at line 218 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::getImplementation(), TeGeneralizedProxMatrix< Set >::gpm_id_, TeGeneralizedProxMatrix< Set >::imp_, TeGeneralizedProxMatrix< Set >::impl_strategy_, TeGeneralizedProxMatrix< Set >::is_default_, TeGeneralizedProxMatrix< Set >::neighbourhood_table_, TeGeneralizedProxMatrix< Set >::sc_, TeGeneralizedProxMatrix< Set >::ss_, TeGeneralizedProxMatrix< Set >::sw_, TeCELLS, TeGraphBreymann, TePOLYGONS, and TeGeneralizedProxMatrix< Set >::total_slices_.
00219 { 00220 gpm_id_=-1; 00221 is_default_=false; 00222 total_slices_=1; 00223 neighbourhood_table_=""; 00224 impl_strategy_=TeGraphBreymann; 00225 00226 imp_ = 0; 00227 imp_ = getImplementation(imp_type); 00228 if ((geom_type==TePOLYGONS) || (geom_type==TeCELLS)) 00229 { 00230 sc_ = new TeProxMatrixLocalAdjacencyStrategy (objects, geom_type); 00231 ss_ = new TeProxMatrixNoSlicingStrategy; 00232 sw_ = new TeProxMatrixNoWeightsStrategy; 00233 } 00234 else 00235 { 00236 imp_ = 0; 00237 sc_ = 0; 00238 ss_ = 0; 00239 sw_ = 0; 00240 } 00241 }
| TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix | ( | const TeGeneralizedProxMatrix< Set > & | p | ) | [inline] |
Definition at line 290 of file TeGeneralizedProxMatrix.h.
References TeProxMatrixImplementation::createCopy(), TeGeneralizedProxMatrix< Set >::gpm_id_, TeGeneralizedProxMatrix< Set >::imp_, TeGeneralizedProxMatrix< Set >::impl_strategy_, TeGeneralizedProxMatrix< Set >::is_default_, TeGeneralizedProxMatrix< Set >::neighbourhood_table_, TeGeneralizedProxMatrix< Set >::sc_, TeGeneralizedProxMatrix< Set >::ss_, TeGeneralizedProxMatrix< Set >::sw_, and TeGeneralizedProxMatrix< Set >::total_slices_.
00291 { 00292 if (pm.imp_ == 0) 00293 imp_ = 0; 00294 else 00295 imp_ = pm.imp_->createCopy (); 00296 00297 sc_ = pm.sc_; 00298 ss_ = pm.ss_; 00299 sw_ = pm.sw_; 00300 00301 gpm_id_=pm.gpm_id_; 00302 is_default_=pm.is_default_; 00303 total_slices_=pm.total_slices_; 00304 neighbourhood_table_=pm.neighbourhood_table_; 00305 impl_strategy_=pm.impl_strategy_; 00306 }
| virtual TeGeneralizedProxMatrix< Set >::~TeGeneralizedProxMatrix | ( | ) | [inline, virtual] |
Definition at line 209 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_.
| bool TeGeneralizedProxMatrix< Set >::clearImplementation | ( | ) | [inline] |
Definition at line 483 of file TeGeneralizedProxMatrix.h.
References aux, TeGeneralizedProxMatrix< Set >::getImplementation(), TeGeneralizedProxMatrix< Set >::imp_, and TeProxMatrixImplementation::type().
00484 { 00485 TeProxMatrixImplementation* aux; 00486 if (imp_ == 0) 00487 aux = getImplementation (); 00488 else 00489 aux = getImplementation (imp_->type()); 00490 00491 if (aux == 0) 00492 return false; 00493 00494 delete imp_; 00495 imp_ = aux; 00496 00497 return true; 00498 }
| bool TeGeneralizedProxMatrix< Set >::connectObjects | ( | const string & | object_id1, | |
| const string & | object_id2 | |||
| ) | [inline] |
Definition at line 538 of file TeGeneralizedProxMatrix.h.
References TeProxMatrixImplementation::connectObjects(), TeGeneralizedProxMatrix< Set >::getImplementation(), and TeGeneralizedProxMatrix< Set >::imp_.
00539 { 00540 if (!imp_) 00541 getImplementation(); 00542 TeProxMatrixAttributes attr; 00543 imp_->connectObjects (object_id1, object_id2, attr); 00544 return true; 00545 }
| bool TeGeneralizedProxMatrix< Set >::connectObjects | ( | const string & | object_id1, | |
| const string & | object_id2, | |||
| const TeProxMatrixAttributes & | attr | |||
| ) | [inline] |
Definition at line 529 of file TeGeneralizedProxMatrix.h.
References TeProxMatrixImplementation::connectObjects(), TeGeneralizedProxMatrix< Set >::getImplementation(), and TeGeneralizedProxMatrix< Set >::imp_.
00530 { 00531 if (!imp_) 00532 getImplementation(); 00533 imp_->connectObjects (object_id1, object_id2, attr); 00534 return true; 00535 }
| bool TeGeneralizedProxMatrix< Set >::constructMatrix | ( | ) | [inline] |
Definition at line 454 of file TeGeneralizedProxMatrix.h.
References TeProxMatrixWeightsStrategy::ComputeWeigths(), TeProxMatrixConstructionStrategy< T >::Construct(), TeGeneralizedProxMatrix< Set >::getImplementation(), TeGeneralizedProxMatrix< Set >::imp_, TeGeneralizedProxMatrix< Set >::isValid(), TeGeneralizedProxMatrix< Set >::sc_, TeProxMatrixSlicingStrategy::Slice(), TeGeneralizedProxMatrix< Set >::ss_, and TeGeneralizedProxMatrix< Set >::sw_.
Referenced by main().
00455 { 00456 if(!isValid()) 00457 return false; 00458 00459 // ClearImplementation(); 00460 imp_ = 0; 00461 imp_ = getImplementation(); 00462 00463 if (sc_) 00464 { 00465 if (sc_->Construct (imp_)) 00466 { 00467 if (ss_) 00468 ss_->Slice (imp_); 00469 if (sw_) 00470 sw_->ComputeWeigths (imp_); 00471 return true; 00472 } 00473 } 00474 imp_ = 0; 00475 sc_ = 0; 00476 ss_ = 0; 00477 sw_ = 0; 00478 return false; 00479 }
| bool TeGeneralizedProxMatrix< Set >::disconnectObjects | ( | const string & | object_id1, | |
| const string & | object_id2 | |||
| ) | [inline] |
Definition at line 548 of file TeGeneralizedProxMatrix.h.
References TeProxMatrixImplementation::disconnectObjects(), and TeGeneralizedProxMatrix< Set >::imp_.
00549 { 00550 if (imp_ == 0) 00551 return false; 00552 return imp_->disconnectObjects (object_id1, object_id2); 00553 }
| bool TeGeneralizedProxMatrix< Set >::getConnectionAttributes | ( | const string & | object_id1, | |
| string & | object_id2, | |||
| TeProxMatrixAttributes & | attr | |||
| ) | [inline] |
Definition at line 564 of file TeGeneralizedProxMatrix.h.
References TeProxMatrixImplementation::getConnectionAttributes(), and TeGeneralizedProxMatrix< Set >::imp_.
00565 { 00566 if (imp_ == 0) 00567 return false; 00568 return imp_->getConnectionAttributes (object_id1, object_id2, attr); 00569 }
| TeProxMatrixConstructionParams* TeGeneralizedProxMatrix< Set >::getConstructionParams | ( | ) | [inline] |
Definition at line 132 of file TeGeneralizedProxMatrix.h.
References TeProxMatrixConstructionStrategy< T >::constructionParams(), and TeGeneralizedProxMatrix< Set >::sc_.
00133 { 00134 if(sc_) 00135 return &(sc_->constructionParams()); 00136 return 0; 00137 }
| TeProxMatrixImplementation * TeGeneralizedProxMatrix< Set >::getImplementation | ( | const TeGPMImplementation & | implementation_type = TeGraphBreymann |
) | [inline, protected] |
Definition at line 280 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, and TeProxMatrixAbstractFactory::MakeConcreteImplementation().
Referenced by TeGeneralizedProxMatrix< Set >::clearImplementation(), TeGeneralizedProxMatrix< Set >::connectObjects(), TeGeneralizedProxMatrix< Set >::constructMatrix(), and TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix().
00281 { 00282 if (imp_ == 0) 00283 imp_ = TeProxMatrixAbstractFactory::MakeConcreteImplementation (type); 00284 return imp_; 00285 }
| TeNeighboursMap TeGeneralizedProxMatrix< Set >::getMapNeighbours | ( | const string & | object_id, | |
| int | slice = 1 | |||
| ) | [inline] |
Definition at line 377 of file TeGeneralizedProxMatrix.h.
References TeNeighbours::Attributes(), TeProxMatrixImplementation::getNeighbours(), TeGeneralizedProxMatrix< Set >::imp_, TeNeighbours::ObjectId(), TeNeighbours::size(), TeProxMatrixAttributes::Slice(), and TeGeneralizedProxMatrix< Set >::total_slices_.
Referenced by main(), and TeCreateDissMatrix().
00378 { 00379 TeNeighboursMap neighMap; 00380 if (slice > total_slices_) 00381 return neighMap; 00382 00383 if (imp_) 00384 { 00385 TeNeighbours neigh; 00386 imp_->getNeighbours (object_id, neigh); 00387 00388 for (int i=0; i < neigh.size(); i++) 00389 if (neigh.Attributes(i).Slice() == slice) 00390 neighMap[neigh.ObjectId(i)] = neigh.Attributes(i); 00391 } 00392 00393 return neighMap; 00394 }
| TeNeighbours TeGeneralizedProxMatrix< Set >::getNeighbours | ( | const string & | object_id, | |
| int | slice = 1 | |||
| ) | [inline] |
Definition at line 350 of file TeGeneralizedProxMatrix.h.
References TeNeighbours::Attributes(), TeProxMatrixImplementation::getNeighbours(), TeGeneralizedProxMatrix< Set >::imp_, TeNeighbours::Insert(), TeNeighbours::ObjectId(), TeNeighbours::size(), TeProxMatrixAttributes::Slice(), and TeGeneralizedProxMatrix< Set >::total_slices_.
Referenced by TeGeneralizedProxMatrix< Set >::operator[]().
00351 { 00352 TeNeighbours neigh2; 00353 if (slice > total_slices_) 00354 return neigh2; 00355 00356 if (imp_) 00357 { 00358 TeNeighbours neigh1; 00359 imp_->getNeighbours (object_id, neigh1); 00360 for (int i=0; i < neigh1.size(); i++) 00361 if (neigh1.Attributes(i).Slice() == slice) 00362 neigh2.Insert (neigh1.ObjectId(i), neigh1.Attributes(i)); 00363 } 00364 00365 return neigh2; 00366 }
| TeProxMatrixSlicingParams* TeGeneralizedProxMatrix< Set >::getSlicingParams | ( | ) | [inline] |
Definition at line 148 of file TeGeneralizedProxMatrix.h.
References TeProxMatrixSlicingStrategy::slicingParams(), and TeGeneralizedProxMatrix< Set >::ss_.
00149 { 00150 if(ss_) 00151 return &(ss_->slicingParams()); 00152 return 0; 00153 }
| TeSTElementSet TeGeneralizedProxMatrix< Set >::getSTENeighbours | ( | const string & | object_id | ) | [inline] |
Definition at line 398 of file TeGeneralizedProxMatrix.h.
References TeProxMatrixImplementation::getNeighbours(), TeGeneralizedProxMatrix< Set >::imp_, TeBaseSTInstanceSet< GeometryType, TimeType, InstanceType >::insertSTInstance(), TeNeighbours::ObjectId(), TeBaseSTInstance< GeometryType, TimeType >::objectId(), TeProxMatrixConstructionStrategy< T >::objects(), TeBaseSTInstance< GeometryType, TimeType >::properties(), TeGeneralizedProxMatrix< Set >::sc_, and TeNeighbours::size().
00399 { 00400 TeSTElementSet selected_objects; 00401 if (imp_ && sc_) 00402 { 00403 TeNeighbours neigh; 00404 imp_->getNeighbours (object_id, neigh); 00405 00406 for (int i = 0; i < neigh.size(); i++) 00407 { 00408 // Construct a sto instance with its attributes 00409 TeSTInstance obj; 00410 obj.objectId(neigh.ObjectId(i)); 00411 00412 //load the attributes 00413 TePropertyVector propVector; 00414 sc_->objects()->getPropertyVector(object_id, propVector); 00415 obj.properties(propVector); 00416 00417 // insert object in the return vector 00418 selected_objects.insertSTInstance(obj); 00419 } 00420 } 00421 return selected_objects; 00422 }
| TeProxMatrixWeightsParams* TeGeneralizedProxMatrix< Set >::getWeightsParams | ( | ) | [inline] |
Definition at line 140 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::sw_, and TeProxMatrixWeightsStrategy::weightsParams().
00141 { 00142 if(sw_) 00143 return &(sw_->weightsParams()); 00144 return 0; 00145 }
| bool TeGeneralizedProxMatrix< Set >::isConnected | ( | const string & | object_id1, | |
| const string & | object_id2 | |||
| ) | [inline] |
Definition at line 521 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, and TeProxMatrixImplementation::isConnected().
00522 { 00523 if (imp_ == 0) 00524 return false; 00525 return imp_->isConnected (object_id1, object_id2); 00526 }
| bool TeGeneralizedProxMatrix< Set >::isValid | ( | ) | const [inline, protected] |
Definition at line 270 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, TeGeneralizedProxMatrix< Set >::sc_, TeGeneralizedProxMatrix< Set >::ss_, and TeGeneralizedProxMatrix< Set >::sw_.
Referenced by TeGeneralizedProxMatrix< Set >::constructMatrix(), TeGeneralizedProxMatrix< Set >::operator==(), TeGeneralizedProxMatrix< Set >::recomputeSlicing(), and TeGeneralizedProxMatrix< Set >::recomputeWeights().
00271 { 00272 if ((imp_) && (sc_) && (ss_) && (sw_)) 00273 return true; 00274 00275 return false; 00276 }
| int TeGeneralizedProxMatrix< Set >::numberOfObjects | ( | ) | [inline] |
Definition at line 572 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, and TeProxMatrixImplementation::numberOfObjects().
00573 { 00574 if (imp_ == 0) 00575 return 0; 00576 return imp_->numberOfObjects (); 00577 }
| int TeGeneralizedProxMatrix< Set >::numerOfSlices | ( | ) | [inline] |
Definition at line 188 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::total_slices_.
00188 {return total_slices_;}
| TeGeneralizedProxMatrix< Set > & TeGeneralizedProxMatrix< Set >::operator= | ( | const TeGeneralizedProxMatrix< Set > & | p | ) | [inline] |
Definition at line 310 of file TeGeneralizedProxMatrix.h.
References TeProxMatrixImplementation::createCopy(), TeGeneralizedProxMatrix< Set >::gpm_id_, TeGeneralizedProxMatrix< Set >::imp_, TeGeneralizedProxMatrix< Set >::impl_strategy_, TeGeneralizedProxMatrix< Set >::is_default_, TeGeneralizedProxMatrix< Set >::neighbourhood_table_, TeGeneralizedProxMatrix< Set >::sc_, TeGeneralizedProxMatrix< Set >::ss_, TeGeneralizedProxMatrix< Set >::sw_, and TeGeneralizedProxMatrix< Set >::total_slices_.
00311 { 00312 if (*this == pm) return *this; 00313 00314 if (imp_) delete imp_; 00315 imp_ = 0; 00316 if (pm.imp_) imp_ = pm.imp_->createCopy (); 00317 00318 sc_ = pm.sc_; 00319 ss_ = pm.ss_; 00320 sw_ = pm.sw_; 00321 gpm_id_=pm.gpm_id_; 00322 is_default_=pm.is_default_; 00323 total_slices_=pm.total_slices_; 00324 neighbourhood_table_=pm.neighbourhood_table_; 00325 impl_strategy_=pm.impl_strategy_; 00326 00327 return *this; 00328 00329 }
| bool TeGeneralizedProxMatrix< Set >::operator== | ( | const TeGeneralizedProxMatrix< Set > & | p | ) | const [inline] |
Definition at line 332 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, TeProxMatrixImplementation::isEqual(), TeProxMatrixConstructionStrategy< T >::IsEqual(), TeGeneralizedProxMatrix< Set >::isValid(), TeGeneralizedProxMatrix< Set >::sc_, TeGeneralizedProxMatrix< Set >::ss_, TeGeneralizedProxMatrix< Set >::sw_, and TeGeneralizedProxMatrix< Set >::total_slices_.
00333 { 00334 if (isValid() && pm.isValid()) 00335 { 00336 if ((sc_->IsEqual (*(pm.sc_))) && 00337 (ss_->operator==(*(pm.ss_))) && 00338 (sw_->operator==(*(pm.sw_))) && 00339 (total_slices_ == pm.total_slices_) && 00340 (imp_->isEqual(*(pm.imp_)))) 00341 return true; 00342 } 00343 else 00344 if (!isValid() && !pm.isValid()) 00345 return true; 00346 return false; 00347 }
| TeNeighbours TeGeneralizedProxMatrix< Set >::operator[] | ( | const string & | object_id | ) | [inline] |
Definition at line 370 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::getNeighbours().
00371 { 00372 return getNeighbours(object_id); 00373 }
| bool TeGeneralizedProxMatrix< Set >::recomputeSlicing | ( | ) | [inline] |
Definition at line 511 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, TeGeneralizedProxMatrix< Set >::isValid(), TeProxMatrixSlicingStrategy::Slice(), and TeGeneralizedProxMatrix< Set >::ss_.
00512 { 00513 if (isValid()){ 00514 ss_->Slice (imp_); return true; 00515 } 00516 return false; 00517 }
| bool TeGeneralizedProxMatrix< Set >::recomputeWeights | ( | ) | [inline] |
Definition at line 501 of file TeGeneralizedProxMatrix.h.
References TeProxMatrixWeightsStrategy::ComputeWeigths(), TeGeneralizedProxMatrix< Set >::imp_, TeGeneralizedProxMatrix< Set >::isValid(), and TeGeneralizedProxMatrix< Set >::sw_.
00502 { 00503 if (isValid()){ 00504 sw_->ComputeWeigths (imp_); return true; 00505 } 00506 return false; 00507 }
| bool TeGeneralizedProxMatrix< Set >::removeObject | ( | const string & | object_id | ) | [inline] |
Definition at line 556 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, and TeProxMatrixImplementation::removeObject().
00557 { 00558 if (imp_ == 0) 00559 return false; 00560 return imp_->removeObject (object_id); 00561 }
| bool TeGeneralizedProxMatrix< Set >::saveGALFile | ( | const string & | name, | |
| vector< string > * | ids | |||
| ) | [inline] |
Definition at line 614 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, and TeProxMatrixImplementation::saveGALFile().
00615 { 00616 if (imp_ == 0) 00617 return false; 00618 return imp_->saveGALFile (name, ids); 00619 }
| bool TeGeneralizedProxMatrix< Set >::saveGALFile | ( | const string & | name, | |
| map< string, string > * | ids = 0 | |||
| ) | [inline] |
Definition at line 589 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, and TeProxMatrixImplementation::saveGALFile().
00590 { 00591 if (imp_ == 0) 00592 return false; 00593 return imp_->saveGALFile (name, ids); 00594 }
| bool TeGeneralizedProxMatrix< Set >::saveGWTFile | ( | const string & | name, | |
| vector< string > * | ids | |||
| ) | [inline] |
Definition at line 622 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, and TeProxMatrixImplementation::saveGWTFile().
00623 { 00624 if (imp_ == 0) 00625 return false; 00626 return imp_->saveGWTFile (name, ids); 00627 }
| bool TeGeneralizedProxMatrix< Set >::saveGWTFile | ( | const string & | name, | |
| map< string, string > * | ids = 0 | |||
| ) | [inline] |
Definition at line 597 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, and TeProxMatrixImplementation::saveGWTFile().
00598 { 00599 if (imp_ == 0) 00600 return false; 00601 return imp_->saveGWTFile (name, ids); 00602 }
| bool TeGeneralizedProxMatrix< Set >::saveTextFile | ( | const string & | name, | |
| vector< string > * | ids | |||
| ) | [inline] |
Definition at line 605 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, and TeProxMatrixImplementation::saveTextFile().
00606 { 00607 if (imp_ == 0) 00608 return false; 00609 return imp_->saveTextFile (name, ids); 00610 }
| bool TeGeneralizedProxMatrix< Set >::saveTextFile | ( | const string & | name, | |
| map< string, string > * | ids = 0 | |||
| ) | [inline] |
Definition at line 580 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::imp_, and TeProxMatrixImplementation::saveTextFile().
00581 { 00582 if (imp_ == 0) 00583 return false; 00584 return imp_->saveTextFile (name, ids); 00585 }
| bool TeGeneralizedProxMatrix< Set >::setCurrentConstructionStrategy | ( | TeProxMatrixConstructionStrategy< Set > * | sc | ) | [inline] |
Definition at line 426 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::sc_.
00427 { 00428 if (sc == 0) 00429 return false; 00430 sc_ = sc; 00431 return true; 00432 }
| bool TeGeneralizedProxMatrix< Set >::setCurrentSlicingStrategy | ( | TeProxMatrixSlicingStrategy * | ss | ) | [inline] |
Definition at line 445 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::ss_.
00446 { 00447 if (ss == 0) 00448 return false; 00449 ss_ = ss; 00450 return true; 00451 }
| bool TeGeneralizedProxMatrix< Set >::setCurrentWeightsStrategy | ( | TeProxMatrixWeightsStrategy * | sw | ) | [inline] |
Definition at line 436 of file TeGeneralizedProxMatrix.h.
References TeGeneralizedProxMatrix< Set >::sw_.
00437 { 00438 if (sw == 0) 00439 return false; 00440 sw_ = sw; 00441 return true; 00442 }
| int TeGeneralizedProxMatrix< Set >::gpm_id_ |
Definition at line 56 of file TeGeneralizedProxMatrix.h.
Referenced by TeGeneralizedProxMatrix< Set >::operator=(), and TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix().
TeProxMatrixImplementation* TeGeneralizedProxMatrix< Set >::imp_ [private] |
Definition at line 43 of file TeGeneralizedProxMatrix.h.
Referenced by TeGeneralizedProxMatrix< Set >::clearImplementation(), TeGeneralizedProxMatrix< Set >::connectObjects(), TeGeneralizedProxMatrix< Set >::constructMatrix(), TeGeneralizedProxMatrix< Set >::disconnectObjects(), TeGeneralizedProxMatrix< Set >::getConnectionAttributes(), TeGeneralizedProxMatrix< Set >::getImplementation(), TeGeneralizedProxMatrix< Set >::getMapNeighbours(), TeGeneralizedProxMatrix< Set >::getNeighbours(), TeGeneralizedProxMatrix< Set >::getSTENeighbours(), TeGeneralizedProxMatrix< Set >::isConnected(), TeGeneralizedProxMatrix< Set >::isValid(), TeGeneralizedProxMatrix< Set >::numberOfObjects(), TeGeneralizedProxMatrix< Set >::operator=(), TeGeneralizedProxMatrix< Set >::operator==(), TeGeneralizedProxMatrix< Set >::recomputeSlicing(), TeGeneralizedProxMatrix< Set >::recomputeWeights(), TeGeneralizedProxMatrix< Set >::removeObject(), TeGeneralizedProxMatrix< Set >::saveGALFile(), TeGeneralizedProxMatrix< Set >::saveGWTFile(), TeGeneralizedProxMatrix< Set >::saveTextFile(), TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix(), and TeGeneralizedProxMatrix< Set >::~TeGeneralizedProxMatrix().
| TeGPMImplementation TeGeneralizedProxMatrix< Set >::impl_strategy_ |
Definition at line 60 of file TeGeneralizedProxMatrix.h.
Referenced by TeGeneralizedProxMatrix< Set >::operator=(), and TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix().
| bool TeGeneralizedProxMatrix< Set >::is_default_ |
Definition at line 57 of file TeGeneralizedProxMatrix.h.
Referenced by TeGeneralizedProxMatrix< Set >::operator=(), and TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix().
| string TeGeneralizedProxMatrix< Set >::neighbourhood_table_ |
Definition at line 59 of file TeGeneralizedProxMatrix.h.
Referenced by TeGeneralizedProxMatrix< Set >::operator=(), and TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix().
TeProxMatrixConstructionStrategy<Set>* TeGeneralizedProxMatrix< Set >::sc_ [private] |
Definition at line 44 of file TeGeneralizedProxMatrix.h.
Referenced by TeGeneralizedProxMatrix< Set >::constructMatrix(), TeGeneralizedProxMatrix< Set >::getConstructionParams(), TeGeneralizedProxMatrix< Set >::getSTENeighbours(), TeGeneralizedProxMatrix< Set >::isValid(), TeGeneralizedProxMatrix< Set >::operator=(), TeGeneralizedProxMatrix< Set >::operator==(), TeGeneralizedProxMatrix< Set >::setCurrentConstructionStrategy(), and TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix().
TeProxMatrixSlicingStrategy* TeGeneralizedProxMatrix< Set >::ss_ [private] |
Definition at line 45 of file TeGeneralizedProxMatrix.h.
Referenced by TeGeneralizedProxMatrix< Set >::constructMatrix(), TeGeneralizedProxMatrix< Set >::getSlicingParams(), TeGeneralizedProxMatrix< Set >::isValid(), TeGeneralizedProxMatrix< Set >::operator=(), TeGeneralizedProxMatrix< Set >::operator==(), TeGeneralizedProxMatrix< Set >::recomputeSlicing(), TeGeneralizedProxMatrix< Set >::setCurrentSlicingStrategy(), and TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix().
TeProxMatrixWeightsStrategy* TeGeneralizedProxMatrix< Set >::sw_ [private] |
Definition at line 46 of file TeGeneralizedProxMatrix.h.
Referenced by TeGeneralizedProxMatrix< Set >::constructMatrix(), TeGeneralizedProxMatrix< Set >::getWeightsParams(), TeGeneralizedProxMatrix< Set >::isValid(), TeGeneralizedProxMatrix< Set >::operator=(), TeGeneralizedProxMatrix< Set >::operator==(), TeGeneralizedProxMatrix< Set >::recomputeWeights(), TeGeneralizedProxMatrix< Set >::setCurrentWeightsStrategy(), and TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix().
| int TeGeneralizedProxMatrix< Set >::total_slices_ |
Definition at line 58 of file TeGeneralizedProxMatrix.h.
Referenced by TeGeneralizedProxMatrix< Set >::getMapNeighbours(), TeGeneralizedProxMatrix< Set >::getNeighbours(), TeGeneralizedProxMatrix< Set >::numerOfSlices(), TeGeneralizedProxMatrix< Set >::operator=(), TeGeneralizedProxMatrix< Set >::operator==(), and TeGeneralizedProxMatrix< Set >::TeGeneralizedProxMatrix().
1.5.3