# HG changeset patch # User Claus Gittinger # Date 1478271396 -3600 # Node ID ca9de5588d1f5288849e33e3cab779d973a355f1 # Parent 4a410e6b1dff38e929c3bba4e4e55fb03f9fd33e #DOCUMENTATION by cg class: Collection comment/format in: #firstIfEmpty: diff -r 4a410e6b1dff -r ca9de5588d1f Collection.st --- a/Collection.st Fri Nov 04 15:56:13 2016 +0100 +++ b/Collection.st Fri Nov 04 15:56:36 2016 +0100 @@ -1,5 +1,3 @@ -"{ Encoding: utf8 }" - " COPYRIGHT (c) 1989 by Claus Gittinger All Rights Reserved @@ -275,7 +273,6 @@ ^ self newWithSize:n ! ! - !Collection class methodsFor:'Signal constants'! emptyCollectionSignal @@ -550,7 +547,6 @@ "Created: / 22-10-2008 / 21:29:27 / cg" ! ! - !Collection methodsFor:'accessing'! anElement @@ -705,7 +701,7 @@ firstIfEmpty:exceptionValue "return the first element of the collection. If its empty, return the exceptionValue. - (i.e. dont trigger an error as done in #first)" + (i.e. don't trigger an error as done in #first)" self isEmpty ifTrue:[^ exceptionValue value]. ^ self first @@ -4341,7 +4337,7 @@ aStream nextPut:$) " - #(1 2 3 'hello' $a $ü) printOn:Transcript + #(1 2 3 'hello' $a $ü) printOn:Transcript (Array new:100000) printOn:Transcript (Array new:100000) printOn:Stdout (Array new:100000) printString size @@ -5695,7 +5691,7 @@ includesAll:aCollection "return true if the receiver includes all elements of the argument, aCollection; false if any is missing. - Notice: this method has O² runtime behavior and may be + Notice: this method has O² runtime behavior and may be slow for big receivers/args. Think about using a Set, or Dictionary." @@ -5715,7 +5711,7 @@ Return false if it includes none. Uses #= (value compare) Notice: - this method has O² runtime behavior for some subclasses and may be slow for big receivers/args. + this method has O² runtime behavior for some subclasses and may be slow for big receivers/args. Think about using a Set or Dictionary. Some speedup is also possible, by arranging highly probable elements towards the beginning of aCollection, to avoid useless searches. @@ -5785,7 +5781,7 @@ Return false if it includes none. Use identity compare for comparing. Notice: - this method has O² runtime behavior for some subclasses and may be slow for big receivers/args. + this method has O² runtime behavior for some subclasses and may be slow for big receivers/args. Think about using a Set or Dictionary. Some speedup is also possible, by arranging highly probable elements towards the beginning of aCollection, to avoid useless searches." @@ -6001,7 +5997,6 @@ ^ aVisitor visitCollection:self with:aParameter ! ! - !Collection class methodsFor:'documentation'! version