class: ChangeSet
authorClaus Gittinger <cg@exept.de>
Sat, 31 Jan 2015 15:23:47 +0100
changeset 3732 f3bf00a70315
parent 3731 3c1c1ddf02e2
child 3733 406ed5a2c24d
class: ChangeSet comment/format in:8 methods
ChangeSet.st
--- a/ChangeSet.st	Wed Jan 28 21:44:19 2015 +0100
+++ b/ChangeSet.st	Sat Jan 31 15:23:47 2015 +0100
@@ -445,6 +445,10 @@
 
 fromBeeStream:aStream while:aConditionBlock
     "build a changeSet from a Bee Smalltalk .bsc stream, containing chunks
+     Pass each change to the conditionBlock and stop whenever that
+     returns false. This allows skipping reamaining chunks, and speeding up
+     reading, if only parts need to be extracted 
+     (for example: only documentation methods).
      Return the changeSet."
 
     |changeSet|
@@ -501,14 +505,14 @@
 !
 
 fromDirectory: aStringOfFilename asSmalltalkXPackage: isSmalltalkXPackage
-      "Read all .st files (non-recursively) from `aStringOrFilename` 
-       Return the resuling ChangeSet.
-
-       If `isSmalltalkXPacklage` is true, then treat directory as Smalltalk/X
-       package directory as checked out from a VCS. Read only those files
-       present in abbrev.stc (if present).
-       "        
-     | directory abbrevFile filter |
+    "Read all .st files (non-recursively) from `aStringOrFilename` 
+     Return the resuling ChangeSet.
+
+     If `isSmalltalkXPacklage` is true, then treat directory as Smalltalk/X
+     package directory as checked out from a VCS. Read only those files
+     present in abbrev.stc (if present)."
+
+    | directory abbrevFile filter |
 
     directory := aStringOfFilename asFilename.
     (isSmalltalkXPackage and:[(abbrevFile := directory asFilename / 'abbrev.stc') exists]) ifTrue:[
@@ -532,9 +536,9 @@
 fromDirectory: aStringOrFilename filter: filter
     "Read all files (non-recursively) from `aStringOrFilename` for which the
      filter return true. Return the resuling ChangeSet"
-    
 
     | d cs files step |
+
     d := aStringOrFilename asFilename.
     cs := self new.    
     files := (d directoryContentsAsFilenames) select:filter.
@@ -567,7 +571,11 @@
 !
 
 fromDolphinPACStream:aStream while:aConditionBlock
-    "build a changeSet from a stream, containing dolphin pac file chunks."
+    "build a changeSet from a stream, containing dolphin pac file chunks.
+     Pass each change to the conditionBlock and stop whenever that
+     returns false. This allows skipping reamaining chunks, and speeding up
+     reading, if only parts need to be extracted 
+     (for example: only documentation methods)."
 
     |changeSet|
 
@@ -585,6 +593,10 @@
 !
 
 fromFile:filenameOrString
+    "build a changeSet from a file, which contains chunks.
+     (i.e. either a classes sourceFile or a change-file).
+     Return the changeSet."
+
     |filename mime stream changeSet|
 
     filename := filenameOrString asFilename.
@@ -641,8 +653,8 @@
 !
 
 fromFileOrDirectory: fileOrDirectory
-
     | f |
+
     f := fileOrDirectory asFilename.
     ^(f isDirectory 
         ifTrue:[self fromDirectory: f]
@@ -651,7 +663,7 @@
         yourself.
 
     "
-        ChangeSet fromFileOrDirectory: (Smalltalk getPackageDirectoryForPackage:'stx:libbasic')
+     ChangeSet fromFileOrDirectory: (Smalltalk getPackageDirectoryForPackage:'stx:libbasic')
     "
 
     "Created: / 02-04-2011 / 00:50:29 / Jan Vrany <jan.vrany@fit.cvut.cz>"
@@ -668,6 +680,10 @@
 fromSIFStream:aStream while:aConditionBlock
     "build a changeSet from a SIF stream, containing chunks
      in smalltalk interchange format.
+     Pass each change to the conditionBlock and stop whenever that
+     returns false. This allows skipping reamaining chunks, and speeding up
+     reading, if only parts need to be extracted 
+     (for example: only documentation methods).
      Return the changeSet."
 
     |changeSet|
@@ -705,6 +721,10 @@
 fromStream:aStream while:aConditionBlock
     "build a changeSet from a stream, containing chunks.
      (i.e. either a classes sourceFile or a change-file).
+     Pass each change to the conditionBlock and stop whenever that
+     returns false. This allows skipping reamaining chunks, and speeding up
+     reading, if only parts need to be extracted 
+     (for example: only documentation methods).
      Return the changeSet."
 
     |changeSet|
@@ -763,7 +783,6 @@
     "Created: / 27.10.1997 / 13:52:54 / cg"
 ! !
 
-
 !ChangeSet class methodsFor:'Compatibility-VW'!
 
 component: component definition: anObject change: changeSymbol
@@ -4171,7 +4190,7 @@
 !
 
 version_SVN
-    ^ '$Id: ChangeSet.st,v 1.253 2014-12-31 09:06:59 cg Exp $'
+    ^ '$Id: ChangeSet.st,v 1.254 2015-01-31 14:23:47 cg Exp $'
 ! !
 
 !ChangeSet::ClassSourceWriter::ClassInfo class methodsFor:'instance creation'!
@@ -4850,11 +4869,11 @@
 !ChangeSet class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic3/ChangeSet.st,v 1.253 2014-12-31 09:06:59 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic3/ChangeSet.st,v 1.254 2015-01-31 14:23:47 cg Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libbasic3/ChangeSet.st,v 1.253 2014-12-31 09:06:59 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic3/ChangeSet.st,v 1.254 2015-01-31 14:23:47 cg Exp $'
 !
 
 version_HG
@@ -4863,6 +4882,6 @@
 !
 
 version_SVN
-    ^ '$Id: ChangeSet.st,v 1.253 2014-12-31 09:06:59 cg Exp $'
+    ^ '$Id: ChangeSet.st,v 1.254 2015-01-31 14:23:47 cg Exp $'
 ! !