Log of /trunk/core/cont/src/TCollection.cxx
Parent Directory
Revision
44507 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Jun 4 12:30:41 2012 UTC (2 years, 7 months ago) by
axel
File length: 20506 byte(s)
Diff to
previous 37411
Remove
using namespace std;
from Riostream.h, which has huge consequences for all of ROOT.
Riostream.h is now a simple wrapper for fstream, iostream, iomanip for backward compatibility; Riosfwd.h simply wraps iosfwd.
Because of templates and their inline functions, Riostream.h needed to be included in headers, too (e.g. TParameter.h), which violated the assumption that Riostream.h is not exposing its using namespace std to headers.
ROOT now requires R__ANSISTREAM, R__SSTREAM, which does not change the set of supported compilers.
Without "using namespace std", several identifiers are now prefixed by std::; e.g. roofit/* source files now have a using namespace std to keep their coding style.
TFile::MakeProject() now generates "using namespace std" to convert the CINT-style class names into C++ ones.
Revision
37411 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Dec 8 17:42:11 2010 UTC (4 years, 1 month ago) by
pcanal
File length: 20496 byte(s)
Diff to
previous 35076
Since the Collection objects do have a name and the Clone method does allow (in other cases) for the name to change, add a TCollection::Clone to implement the name change properly
Revision
25128 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Aug 12 17:59:19 2008 UTC (6 years, 5 months ago) by
pcanal
File length: 20165 byte(s)
Diff to
previous 23198
From Matevz:
* TCollection:
Replace Print() methods
virtual void Print(Option_t *wildcard="") const;
virtual void Print(Option_t *wildcard, Option_t *option) const;
with --------------------------------------------------
virtual void Print(Option_t *option="") const;
virtual void Print(Option_t *option, Int_t recurse) const;
virtual void Print(Option_t *option, const char* wildcard,
Int_t recurse=1) const;
virtual void Print(Option_t *option, TPRegexp& regexp,
Int_t recurse=1) const;
Introduce three new protected methods used to print out collection details.
These are called from the Print() methods and make overriding of what
is printed for a collection / entries easier.
virtual void PrintCollectionHeader(Option_t* option) const;
virtual const char* GetCollectionEntryName(TObject* entry) const;
virtual void PrintCollectionEntry(TObject* entry, Option_t* option,
Int_t recurse) const;
* TMap:
Remove two overloaded Print() methods, implement protected
PrintCollectionEntry() instead.
* TQCommand, TQUndoManager, TQConnection, TQConnectionList
Remove overriden Print() methods. If needed, override
PrintCollectionHeader() or PrintCollectionEntry() instead.
* TAlienJobStatusList
Remove Print(), implement PrintCollectionEntry() instead.
* TAlienResult
Remove overloaded Print(wildcard, option) which no longer exists.
* test/tcollprint.cxx
New file - demonstrates behaviour of Print() methods for TList and TMap.
Revision
23198 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Apr 14 09:23:08 2008 UTC (6 years, 9 months ago) by
rdm
File length: 16746 byte(s)
Diff to
previous 22961
From Anar and me:
The background is the following. While working on the PROOF code I found
that enumerating TList is an inconvenient and a long operation, I had to
write the same code all over the place and make duplications. I tried
to use STD algorithms with it, namely std::for_each, and failed.
I therefore decided to enable std::for_each algorithm for ROOT
Containers/Iterators by making as few as possible changes, without rewriting
iterators at all. Now with only two simple lines of code one is able to
iterate through a container:
TIter iter(&list);
for_each(iter.Begin(), TIter::End(), SEnumFunctor());
or
for_each(iter.Begin(), inter_end, SEnumFunctor());
where iter_end could be an iterator to a middle of the container.
After I had changed Iterators so that they could be used with std::for_each,
I decided to go further and did some more changes. As a result,
- I have updated CINT implementation of some algorithms (they look now
more or less better in terms of the standard),
- TList and TObjArray can be now used with std::for_each, std::find_if,
std::count_if (probably with some more algorithms. I've listed here
only what has been *checked* by me). Other containers will be supported
in a next patch.
- A test program has been added: $ROOTSYS/test/stressIterators.cxx
- A tutorial macro has been added: $ROOTSYS/tutorials/cont/TListAndSTL.C
Patch has been verified on Linux, MacOS X, Solaris 10 i386 and Windows.
Revision
22961 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Apr 3 13:32:57 2008 UTC (6 years, 9 months ago) by
rdm
File length: 16285 byte(s)
Diff to
previous 21838
move the directories:
base clib cont meta metautils newdelete pcre rint thread unix utils
winnt zip
under the new core meta directory.
Revision
17412 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Sat Jan 20 19:29:35 2007 UTC (8 years ago) by
brun
Original Path:
trunk/cont/src/TCollection.cxx
File length: 16260 byte(s)
Diff to
previous 17315
-Remove Varargs.h from TString.h and TObject.h and add this include
in the few files that need it.
-Move the following enums from TBuffer.h to TBufferFile.h
enum { kMapSize = 503 };
enum { kStreamedMemberWise = BIT(14) }; //added to version number to know if a collection has been stored member-wise
enum { kNotDecompressed = BIT(15) }; //indicates a weird buffer, used by TBasket
enum { kCannotHandleMemberWiseStreaming = BIT(17), //if set TClonesArray should not use memeber wise streaming
kTextBasedStreaming = BIT(18) }; // indicates if buffer used for XML/SQL object streaming
Revision
17306 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Jan 12 16:03:17 2007 UTC (8 years ago) by
brun
Original Path:
trunk/cont/src/TCollection.cxx
File length: 16258 byte(s)
Diff to
previous 15951
TMath::Abs, TMath::Min, TMath::Max, TMath::Sign, TMath::Range
These functions are unfortunately not defined in a standard way in std::
This include is referenced by a new version of TMath.h.
As a result, TMath.h is back compatible with the previous version.
TMathBase.h is used in place of TMath.h in all the classes
that will go into the future miniCore library.
TMath.h and the TMath implementation will go into a new math sub-directory.
TString.h uses TMathBase.h instead of TMath.h.
As a result, it was necessary to include "TMath.h" in some classes
assuming that TMath was included via TString and using other functions
than the ones defined in TMathBase.h
----------------------------------------------------------------------
Revision
14745 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Apr 19 08:22:26 2006 UTC (8 years, 9 months ago) by
rdm
Original Path:
trunk/cont/src/TCollection.cxx
File length: 16233 byte(s)
Diff to
previous 14063
Change the TError.h macros:
Assert -> R__ASSERT
Check -> R__CHECK
Change the TCollection.h macro:
ForEach -> R__FOR_EACH
This to avoid potential problems due too trivial macro names.
The old macros will be removed in the next release. Currently
they will print out warning messages with the advice to move
to the new macro names.
Revision
14063 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Sun Feb 19 21:02:35 2006 UTC (8 years, 11 months ago) by
pcanal
Original Path:
trunk/cont/src/TCollection.cxx
File length: 16310 byte(s)
Diff to
previous 13725
SetOwner is now a virtual function so that it can be customized.
A TClonesArray is always the owner of its content but it's base
class (TObjArray) is never the direct owner. Hence we need to
disable SetOwner for TClonesArray.
Revision
13725 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Dec 16 11:34:13 2005 UTC (9 years, 1 month ago) by
brun
Original Path:
trunk/cont/src/TCollection.cxx
File length: 15800 byte(s)
Diff to
previous 13258
-Start development version 5.09/01
-code fix in cint/src/rflx_gensrc.cxx such that this function still compiles under gcc2.95
(from Valeriy Onoutchine)
-a patch for rootcint (from Philippe)
(As in TCint), when registering a namespace, do not list of a library, to
to avoid the spurrious loading of _one_ of the library defining
an element of the namespace.
Revision
12123 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Jun 22 20:18:12 2005 UTC (9 years, 7 months ago) by
brun
Original Path:
trunk/cont/src/TCollection.cxx
File length: 15512 byte(s)
Diff to
previous 10304
From Constantin Loizides
This patch implements:
- decentralized, automatic mutex initialization,
see R__LOCKGUARD2 in TVirtualMutex
- PROOF parallel startup fixes
- more thread protection (in base, cont, meta, rest to be done)
- cleanups
From Eddy Offermann:
TString::Atoi and Atof are made const.
Revision
10304 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Oct 13 15:30:22 2004 UTC (10 years, 3 months ago) by
rdm
Original Path:
trunk/cont/src/TCollection.cxx
File length: 15487 byte(s)
Diff to
previous 10282
add a new
Print(Option_t *wildcard, Option_t *option)
method which allows wildcarding and the passing of a dedicated option
for the Print() method of the objects in the container. The existing
TCollection::Print(Option_t *wildcard) does only allow the passing of
the wildcard to the Print() of the contained objects, and that is often
not what is desired.
Revision
10282 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Oct 11 22:58:18 2004 UTC (10 years, 3 months ago) by
rdm
Original Path:
trunk/cont/src/TCollection.cxx
File length: 14786 byte(s)
Diff to
previous 9619
implement Hash() for TCollections so that objects inheriting from
TCollection can be found by name in a THashList. Also implement Compare()
so that collection in a collection can be sorted by name. Suggested by
Kris Gulbrandsen.
Revision
9619 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Jul 30 01:12:28 2004 UTC (10 years, 5 months ago) by
rdm
Original Path:
trunk/cont/src/TCollection.cxx
File length: 14446 byte(s)
Diff to
previous 9541
From Philippe:
This patch implements a const Write and keeps the existing non-const
Write. If somebody derived from TObject and overload Write(), they
will be reminded to implement the const version with a warning
similar to:
include/TCollection.h(45): warning #654: overloaded virtual function "TObject::Write" is only partially overridden in class "TCollection"
class TCollection : public TObject {
The implementation of the non-const Write is simple: call the const Write().
Exceptions are TFile and TDirectory which actually can only implement
non const Write (and hence const Write outputs an error message).
Revision
4056 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Feb 22 09:37:29 2002 UTC (12 years, 11 months ago) by
brun
Original Path:
trunk/cont/src/TCollection.cxx
File length: 13834 byte(s)
Diff to
previous 2005
Patch from Mathieu de Naurois adding Thread-safety in many ROOT classes.
A new TVirtualMutex global is defined in TVirtualMutex.h (gCINTmutex).
gCINTMutes is used in TMethodCall to protect concurrent access to CINT.
The R__LOCKGUARD macro is introduced in many classes to check for a mutex.
The performance penalty introduced by the MUTEX logic
-is ZERO in the application has no threads
-about 10% in case of threads
Revision
1205 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Dec 13 15:13:57 2000 UTC (14 years, 1 month ago) by
brun
Original Path:
trunk/cont/src/TCollection.cxx
File length: 12207 byte(s)
Diff to
previous 847
W A R N I N G !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
==================================================================
A very long list of changes in this pre-release of version 3.00.
We have modified the signature of many functions (in particular TObject)
to introduce more constness in the system.
You must change your code if your class derives from TObject and uses
one of the modified functions such as ls, Print, Compare, Hash, etc.
The modified functions in TObject have the following signature:
virtual TObject *Clone() const;
virtual Int_t Compare(const TObject *obj) const;
virtual void Delete(Option_t *option=""); // *MENU*
virtual void DrawClass() const; // *MENU*
virtual void DrawClone(Option_t *option="") const; // *MENU*
virtual void Dump() const; // *MENU*
virtual TObject *FindObject(const TObject *obj) const;
virtual char *GetObjectInfo(Int_t px, Int_t py) const;
virtual ULong_t Hash() const;
virtual void Inspect() const; // *MENU*
virtual Bool_t IsEqual(const TObject *obj) const;
virtual void ls(Option_t *option="") const;
virtual void Print(Option_t *option="") const;
A similar operation has been done with classes such as TH1, TVirtualPad,
TTree, etc.
Revision
612 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Sep 8 16:11:03 2000 UTC (14 years, 4 months ago) by
rdm
Original Path:
trunk/cont/src/TCollection.cxx
File length: 11926 byte(s)
Diff to
previous 585
introduced the concept of ownership for all collections. By calling
TCollection::SetOwner() a collection becomes the owner of its elements.
In those cases the dtor and Clear() method will delete the items and not
just free the container space. Also all collections now make their
TObject part persistent (so the TObject bits are saved). Version numbers
were properly increased.
This form allows you to request diffs between any two revisions of this file.
For each of the two "sides" of the diff,
enter a numeric revision.