Changeset 5624 for source/ariba
- Timestamp:
- Aug 3, 2009, 2:29:12 PM (15 years ago)
- Location:
- source/ariba
- Files:
-
- 16 edited
Legend:
- Unmodified
- Added
- Removed
-
source/ariba/communication/BaseCommunication.cpp
r5618 r5624 244 244 } else { 245 245 LinkDescriptor& linkDesc = queryLocalLink(link); 246 if (linkDesc.isUnspecified()) return EndpointDescriptor::UNSPECIFIED ;246 if (linkDesc.isUnspecified()) return EndpointDescriptor::UNSPECIFIED(); 247 247 return linkDesc.remoteEndpoint; 248 248 } … … 534 534 if (linkSet[i]->localLink == link) return (LinkDescriptor&)*linkSet[i]; 535 535 536 LinkDescriptor ret; 537 ret.unspecified = true; 538 return ret; 536 return LinkDescriptor::UNSPECIFIED(); 539 537 } 540 538 … … 544 542 if (linkSet[i]->remoteLink == link) return (LinkDescriptor&)*linkSet[i]; 545 543 546 LinkDescriptor ret; 547 ret.unspecified = true; 548 return ret; 544 return LinkDescriptor::UNSPECIFIED(); 549 545 } 550 546 -
source/ariba/communication/BaseCommunication.h
r5614 r5624 234 234 localLink(LinkID::UNSPECIFIED), localLocator(NULL), 235 235 remoteLink(LinkID::UNSPECIFIED), remoteLocator(NULL), 236 remoteEndpoint(EndpointDescriptor::UNSPECIFIED), up(false), unspecified(false) {236 up(false) { 237 237 } 238 238 … … 243 243 244 244 bool isUnspecified() const { 245 return unspecified; 245 return (this == &UNSPECIFIED()); 246 } 247 248 static LinkDescriptor& UNSPECIFIED(){ 249 static LinkDescriptor* unspec = NULL; 250 if(unspec == NULL) unspec = new LinkDescriptor(); 251 return *unspec; 246 252 } 247 253 -
source/ariba/communication/EndpointDescriptor.cpp
r5508 r5624 42 42 namespace communication { 43 43 44 const EndpointDescriptor EndpointDescriptor::UNSPECIFIED;45 44 vsznDefault(EndpointDescriptor); 46 45 47 EndpointDescriptor::EndpointDescriptor() 46 EndpointDescriptor::EndpointDescriptor(){ 48 47 } 49 48 50 EndpointDescriptor::~EndpointDescriptor() 49 EndpointDescriptor::~EndpointDescriptor(){ 51 50 52 51 } 53 52 54 53 EndpointDescriptor::EndpointDescriptor(const EndpointDescriptor& rh) : 55 endpoints(rh.endpoints) 54 endpoints(rh.endpoints){ 56 55 } 57 56 58 57 EndpointDescriptor::EndpointDescriptor(const endpoint_set& endpoints ) : 59 endpoints(endpoints) 58 endpoints(endpoints){ 60 59 } 61 60 62 EndpointDescriptor::EndpointDescriptor(const string& str) : endpoints(str) 61 EndpointDescriptor::EndpointDescriptor(const string& str) : endpoints(str){ 63 62 } 64 63 -
source/ariba/communication/EndpointDescriptor.h
r5502 r5624 56 56 57 57 public: 58 /// the unspecified endpoint descriptor59 static const EndpointDescriptor UNSPECIFIED;60 61 58 /// creates an empty endpoint descriptor with zero endpoints 62 59 EndpointDescriptor(); … … 79 76 } 80 77 78 static EndpointDescriptor& UNSPECIFIED() { 79 static EndpointDescriptor* unspec = NULL; 80 if(unspec == NULL) unspec = new EndpointDescriptor(); 81 82 return *unspec; 83 } 84 81 85 /// returns true, if this object is the unspecified object 82 86 bool isUnspecified() const { 83 return this == &UNSPECIFIED;87 return (this == &UNSPECIFIED()); 84 88 } 85 89 -
source/ariba/overlay/BaseOverlay.cpp
r5554 r5624 654 654 // find link descriptor. not found -> return unspecified 655 655 const LinkDescriptor* ld = getDescriptor(link); 656 if (ld==NULL) return EndpointDescriptor::UNSPECIFIED ;656 if (ld==NULL) return EndpointDescriptor::UNSPECIFIED(); 657 657 658 658 // return endpoint-descriptor from base communication … … 670 670 if( overlayInterface == NULL ) { 671 671 logging_error( "overlay interface not set, cannot resolve endpoint" ); 672 return EndpointDescriptor::UNSPECIFIED ;672 return EndpointDescriptor::UNSPECIFIED(); 673 673 } 674 674 -
source/ariba/overlay/BaseOverlay.h
r5556 r5624 269 269 * @param boot A bootstrap node 270 270 */ 271 void joinSpoVNet(const SpoVNetID& id, const EndpointDescriptor& boot = EndpointDescriptor::UNSPECIFIED );271 void joinSpoVNet(const SpoVNetID& id, const EndpointDescriptor& boot = EndpointDescriptor::UNSPECIFIED()); 272 272 273 273 /** -
source/ariba/overlay/messages/JoinReply.h
r5151 r5624 71 71 const OverlayParameterSet _param = OverlayParameterSet::DEFAULT, 72 72 bool _joinAllowed = false, 73 const EndpointDescriptor _bootstrapEp = EndpointDescriptor::UNSPECIFIED 73 const EndpointDescriptor _bootstrapEp = EndpointDescriptor::UNSPECIFIED() 74 74 ); 75 75 -
source/ariba/overlay/modules/OverlayInterface.h
r5316 r5624 103 103 * end-point, if this node is the initiator 104 104 */ 105 virtual void joinOverlay(const EndpointDescriptor& bootstrap = 106 EndpointDescriptor::UNSPECIFIED ) = 0; 105 virtual void joinOverlay(const EndpointDescriptor& bootstrap = EndpointDescriptor::UNSPECIFIED()) = 0; 107 106 108 107 /** -
source/ariba/overlay/modules/chord/Chord.cpp
r5555 r5624 133 133 const EndpointDescriptor& Chord::resolveNode(const NodeID& node) { 134 134 const route_item* item = table->get(node); 135 if (item == NULL || item->info.isUnspecified()) return EndpointDescriptor::UNSPECIFIED ;135 if (item == NULL || item->info.isUnspecified()) return EndpointDescriptor::UNSPECIFIED(); 136 136 return baseoverlay.getEndpointDescriptor(item->info); 137 137 } -
source/ariba/overlay/modules/chord/Chord.h
r5316 r5624 104 104 /// @see OverlayInterface.h 105 105 virtual void joinOverlay( 106 const EndpointDescriptor& boot = EndpointDescriptor::UNSPECIFIED 106 const EndpointDescriptor& boot = EndpointDescriptor::UNSPECIFIED() 107 107 ); 108 108 -
source/ariba/overlay/modules/onehop/OneHop.cpp
r5316 r5624 71 71 72 72 OverlayNodeMapping::const_iterator i = overlayNodes.find( node ); 73 if (i == overlayNodes.end()) return EndpointDescriptor::UNSPECIFIED ;73 if (i == overlayNodes.end()) return EndpointDescriptor::UNSPECIFIED(); 74 74 75 75 const EndpointDescriptor& ep = baseoverlay.getEndpointDescriptor( i->second ); -
source/ariba/overlay/modules/onehop/OneHop.h
r5316 r5624 72 72 /// @see OverlayInterface.h 73 73 virtual void joinOverlay(const EndpointDescriptor& boot = 74 EndpointDescriptor::UNSPECIFIED );74 EndpointDescriptor::UNSPECIFIED()); 75 75 76 76 /// @see OverlayInterface.h -
source/ariba/utility/addressing
- Property svn:mergeinfo changed (with no actual effect on merging)
-
source/ariba/utility/bootstrap/modules/bluetoothsdp
- Property svn:mergeinfo changed (with no actual effect on merging)
-
source/ariba/utility/bootstrap/modules/periodicbroadcast
- Property svn:mergeinfo changed (with no actual effect on merging)
-
source/ariba/utility/transport
- Property svn:mergeinfo changed (with no actual effect on merging)
Note:
See TracChangeset
for help on using the changeset viewer.