|
From: Frank V. C. <fr...@us...> - 2001-02-27 13:49:55
|
Update of /cvsroot/corelinux/clfw/clfw
In directory usw-pr-cvs1:/tmp/cvs-serv4163/clfw
Modified Files:
Array.hpp Collection.hpp FrameworkEntity.hpp Makefile.am
MetaType.hpp
Added Files:
IncompatibleClassException.hpp SetCollection.hpp
Log Message:
233863 Collections
***** Error reading new file: [Errno 2] No such file or directory: 'IncompatibleClassException.hpp'
***** Error reading new file: [Errno 2] No such file or directory: 'SetCollection.hpp'
Index: Array.hpp
===================================================================
RCS file: /cvsroot/corelinux/clfw/clfw/Array.hpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** Array.hpp 2001/02/25 15:19:51 1.3
--- Array.hpp 2001/02/27 13:51:10 1.4
***************
*** 34,41 ****
#endif
- #if !defined(__BOUNDSEXCEPTION_HPP)
- #include <corelinux/BoundsException.hpp>
- #endif
-
namespace corelinux
{
--- 34,37 ----
***************
*** 88,92 ****
/// Fetch the current size (# of entities) of the array
! CountCref size( void ) const;
/// Fetch entity at index
--- 84,88 ----
/// Fetch the current size (# of entities) of the array
! virtual Count size( void ) const;
/// Fetch entity at index
***************
*** 105,110 ****
throw (BoundsException);
! //
// Mutators
//
--- 101,115 ----
throw (BoundsException);
+ /// Does the entity exist in the collection
! virtual bool containsElement( FrameworkEntityPtr ) const
! throw (NullPointerException);
!
! /// Does the type exist in the collection
!
! virtual bool containsType( MetaClassPtr ) const
! throw (NullPointerException);
!
!
// Mutators
//
***************
*** 112,123 ****
/// Entity put operator
! ArrayRef operator=( FrameworkEntityPtr )
throw (NullPointerException,BoundsException);
! /// Copy (replace)
ArrayRef operator=( ArrayCref );
! /// Copy (replace)
ArrayRef operator=( ArrayCptr )
--- 117,128 ----
/// Entity put operator
! ArrayRef operator+=( FrameworkEntityPtr )
throw (NullPointerException,BoundsException);
! /// Assignment (replace)
ArrayRef operator=( ArrayCref );
! /// Assignment (replace)
ArrayRef operator=( ArrayCptr )
***************
*** 153,156 ****
--- 158,171 ----
virtual void putAt( Index, FrameworkEntityPtr )
throw (NullPointerException, BoundsException);
+
+ /// Add all the elements from the inbound collection
+
+ virtual void addAll( CollectionCref )
+ throw (BoundsException,IncompatibleClassException);
+
+ /// Add all the elements from the inbound collection at a offset
+
+ virtual void addAll( Index, CollectionCref )
+ throw (BoundsException,IncompatibleClassException);
/// Remove at index
Index: Collection.hpp
===================================================================
RCS file: /cvsroot/corelinux/clfw/clfw/Collection.hpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** Collection.hpp 2001/02/24 04:32:31 1.1
--- Collection.hpp 2001/02/27 13:51:10 1.2
***************
*** 30,35 ****
--- 30,44 ----
#endif
+ #if !defined(__BOUNDSEXCEPTION_HPP)
+ #include <corelinux/BoundsException.hpp>
+ #endif
+
+ #if !defined(__INCOMPATIBLECLASSEXCEPTION_HPP)
+ #include <IncompatibleClassException.hpp>
+ #endif
+
namespace corelinux
{
+ DECLARE_CLASS( MetaClass );
DECLARE_CLASS( Collection );
***************
*** 82,85 ****
--- 91,114 ----
//@}
+
+ //
+ // Minimal functionality forced (replaced with meta info)
+ //
+
+ virtual Count size( void ) const = 0;
+
+ virtual void addAll( CollectionCref )
+ throw (BoundsException,IncompatibleClassException) = 0;
+
+ virtual void addAll( Index, CollectionCref )
+ throw (BoundsException,IncompatibleClassException) = 0;
+
+ virtual void put( FrameworkEntityPtr ) = 0;
+
+ virtual bool containsElement( FrameworkEntityPtr ) const
+ throw (NullPointerException) = 0;
+
+ virtual bool containsType( MetaClassPtr ) const
+ throw (NullPointerException) = 0;
/** @name Accessors
Index: FrameworkEntity.hpp
===================================================================
RCS file: /cvsroot/corelinux/clfw/clfw/FrameworkEntity.hpp,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** FrameworkEntity.hpp 2001/02/24 04:17:25 1.4
--- FrameworkEntity.hpp 2001/02/27 13:51:10 1.5
***************
*** 60,63 ****
--- 60,65 ----
virtual MetaTypePtr getType( void ) const;
+ virtual bool equals( FrameworkEntityCptr ) const;
+
/**
create a new instance of className
Index: Makefile.am
===================================================================
RCS file: /cvsroot/corelinux/clfw/clfw/Makefile.am,v
retrieving revision 1.20
retrieving revision 1.21
diff -C2 -r1.20 -r1.21
*** Makefile.am 2001/02/24 04:32:31 1.20
--- Makefile.am 2001/02/27 13:51:10 1.21
***************
*** 16,19 ****
--- 16,20 ----
UniversalIdentifier.hpp \
ClassException.hpp \
+ IncompatibleClassException.hpp \
AbstractEntityException.hpp \
DescriptorNotFound.hpp \
***************
*** 34,37 ****
--- 35,39 ----
Collection.hpp \
Array.hpp \
+ SetCollection.hpp \
MetaSpace.hpp \
MetaClass.hpp \
Index: MetaType.hpp
===================================================================
RCS file: /cvsroot/corelinux/clfw/clfw/MetaType.hpp,v
retrieving revision 1.28
retrieving revision 1.29
diff -C2 -r1.28 -r1.29
*** MetaType.hpp 2001/02/24 04:17:25 1.28
--- MetaType.hpp 2001/02/27 13:51:10 1.29
***************
*** 70,73 ****
--- 70,77 ----
virtual corelinux::MetaTypePtr getType( void ) const; \
/** \
+ equality checks \
+ */ \
+ virtual bool equals( corelinux::FrameworkEntityCptr ) const; \
+ /** \
create a new instance of className \
\return a pointer to className \
***************
*** 688,691 ****
--- 692,714 ----
{ \
return &theTypeDesc; \
+ } \
+ /** \
+ implements the equals upcalls \
+ */ \
+ bool className::equals( FrameworkEntityCptr aPtr ) const \
+ { \
+ bool isSame( false ); \
+ if( getTypeDescriptor() == aPtr->getType() ) \
+ { \
+ if( this == aPtr ) \
+ { \
+ isSame = true; \
+ } \
+ else \
+ { \
+ ; \
+ } \
+ } \
+ return isSame; \
} \
|