|
From: Frank V. C. <fr...@us...> - 2001-03-31 14:05:05
|
Update of /cvsroot/corelinux/clfw/src/libs/clfw
In directory usw-pr-cvs1:/tmp/cvs-serv21774/src/libs/clfw
Modified Files:
Attribute.cpp Concept.cpp Schema.cpp
Log Message:
Added attributes and re-orged Concept->Schema
Index: Attribute.cpp
===================================================================
RCS file: /cvsroot/corelinux/clfw/src/libs/clfw/Attribute.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** Attribute.cpp 2001/03/30 11:48:38 1.1
--- Attribute.cpp 2001/03/31 14:04:59 1.2
***************
*** 35,39 ****
Attribute::Attribute( void )
:
! Aggregate()
{
}
--- 35,41 ----
Attribute::Attribute( void )
:
! Aggregate(),
! theName( NULLPTR ),
! theValue( NULLPTR )
{
}
***************
*** 45,49 ****
Attribute::Attribute( AttributeCref aType )
:
! Aggregate( aType )
{
; // do nothing
--- 47,53 ----
Attribute::Attribute( AttributeCref aType )
:
! Aggregate( aType ),
! theName( aType.getName() ),
! theValue( aType.getValue() )
{
; // do nothing
***************
*** 65,69 ****
bool Attribute::operator==( AttributeCref aAttribute ) const
{
! return ( this == &aAttribute );
}
--- 69,102 ----
bool Attribute::operator==( AttributeCref aAttribute ) const
{
! bool isSame( false );
!
! if( this->getName() != NULLPTR &&
! aAttribute.getName() != NULLPTR )
! {
! isSame = !(std::strcmp( this->getName(), aAttribute.getName() ));
!
! if( isSame == true )
! {
! if( this->getValue() != NULLPTR &&
! aAttribute.getValue() != NULLPTR )
! {
! isSame = this->getValue()->equals( aAttribute.getValue() );
! }
! else
! {
! ; // do nothing
! }
! }
! else
! {
! ; // do nothing
! }
! }
! else
! {
! ; // do nothing
! }
!
! return isSame;
}
***************
*** 98,104 ****
CLOSE_METATYPE_PARENT;
! // We construct the null values reference
OPEN_INSTANCEDATA( Attribute )
CLOSE_INSTANCEDATA;
--- 131,140 ----
CLOSE_METATYPE_PARENT;
! DEFINE_INSTANCEDATA_DESCRIPTOR( Attribute, CharPtr , Name );
! DEFINE_CLASSINSTANCE_DESCRIPTOR( Attribute, FrameworkEntityPtr, FrameworkEntity, Value );
OPEN_INSTANCEDATA( Attribute )
+ DEFINE_INSTANCEDATA( Attribute, Name )
+ DEFINE_INSTANCEDATA( Attribute, Value )
CLOSE_INSTANCEDATA;
***************
*** 109,113 ****
// we use the abstract macro for autonaming
! DEFINE_ABSTRACT_METATYPE
(
Attribute,
--- 145,149 ----
// we use the abstract macro for autonaming
! DEFINE_METATYPE
(
Attribute,
Index: Concept.cpp
===================================================================
RCS file: /cvsroot/corelinux/clfw/src/libs/clfw/Concept.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** Concept.cpp 2001/03/26 13:17:21 1.1
--- Concept.cpp 2001/03/31 14:05:00 1.2
***************
*** 27,30 ****
--- 27,34 ----
#endif
+ #if !defined(__ATTRIBUTE_HPP)
+ #include <clfw/Attribute.hpp>
+ #endif
+
namespace corelinux
{
***************
*** 77,80 ****
--- 81,108 ----
}
+ AttributePtr Concept::getAttribute( CharPtr )
+ {
+ return AttributePtr( NULLPTR );
+ }
+
+ SetCollectionPtr Concept::getPropertyKeys( void )
+ {
+ return SetCollectionPtr( NULLPTR );
+ }
+
+
+ void Concept::addAttribute( AttributePtr )
+ {
+
+ }
+ void Concept::removeAttribute( AttributePtr )
+ {
+
+ }
+ void Concept::removeAttribute( CharPtr )
+ {
+
+ }
+
//
// MetaType information block
***************
*** 98,104 ****
CLOSE_METATYPE_PARENT;
! // We construct the null values reference
OPEN_INSTANCEDATA( Concept )
CLOSE_INSTANCEDATA;
--- 126,133 ----
CLOSE_METATYPE_PARENT;
! DEFINE_CLASSINSTANCE_DESCRIPTOR( Concept, CollectionPtr, Collection, Properties );
OPEN_INSTANCEDATA( Concept )
+ DEFINE_INSTANCEDATA( Concept, Properties )
CLOSE_INSTANCEDATA;
Index: Schema.cpp
===================================================================
RCS file: /cvsroot/corelinux/clfw/src/libs/clfw/Schema.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** Schema.cpp 2001/03/26 13:17:21 1.1
--- Schema.cpp 2001/03/31 14:05:00 1.2
***************
*** 35,39 ****
Schema::Schema( void )
:
! Aggregate()
{
}
--- 35,39 ----
Schema::Schema( void )
:
! Concept()
{
}
***************
*** 45,49 ****
Schema::Schema( SchemaCref aType )
:
! Aggregate( aType )
{
; // do nothing
--- 45,49 ----
Schema::Schema( SchemaCref aType )
:
! Concept( aType )
{
; // do nothing
***************
*** 95,99 ****
OPEN_METATYPE_PARENTS( Schema )
! DEFINE_METATYPE_PARENT( Aggregate )
CLOSE_METATYPE_PARENT;
--- 95,99 ----
OPEN_METATYPE_PARENTS( Schema )
! DEFINE_METATYPE_PARENT( Concept )
CLOSE_METATYPE_PARENT;
|