--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/FileOperations.st Tue Sep 03 17:23:22 2002 +0200
@@ -0,0 +1,68 @@
+"{ Package: 'stx:libtool2' }"
+
+Object subclass:#FileOperations
+ instanceVariableNames:'errorString result'
+ classVariableNames:''
+ poolDictionaries:''
+ category:'Interface-Support'
+!
+
+
+!FileOperations methodsFor:'accessing'!
+
+errorString
+ "return the value of the static variable 'ErrorString' (automatically generated)"
+
+ ^ errorString
+!
+
+errorString:something
+ "set the value of the static variable 'ErrorString' (automatically generated)"
+
+ errorString := something.
+!
+
+result
+ "return the value of the instance variable 'result' (automatically generated)"
+
+ ^ result
+!
+
+result:something
+ "set the value of the instance variable 'result' (automatically generated)"
+
+ result := something.
+! !
+
+!FileOperations methodsFor:'dialogs'!
+
+fileExistDialogFor:aFile
+ | stream string|
+
+ aFile exists ifTrue:[
+ stream := WriteStream on:''.
+ stream nextPutAll:'overwrite '.
+ stream nextPutAll:(aFile asString).
+ stream nextPutAll:' from '.
+ (aFile modificationTime) printOn:stream format:'%(Day)-%(mon)-%(year) %h:%m:%s'.
+ stream nextPutAll:' with size of '.
+ stream nextPutAll:aFile fileSize asString.
+ stream cr.
+ stream nextPutAll:' with '.
+ stream nextPutAll:aFile asString.
+ stream nextPutAll:' from '.
+ (aFile modificationTime) printOn:stream format:'%(Day)-%(mon)-%(year) %h:%m:%s'.
+ stream nextPutAll:' with size of '.
+ stream nextPutAll:aFile fileSize asString.
+ string := stream contents.
+ stream close.
+ ^ (Dialog confirm:(string)).
+ ].
+ ^ true
+! !
+
+!FileOperations class methodsFor:'documentation'!
+
+version
+ ^ '$Header$'
+! !