[PATCH] Use multiple <filein> tags for NetClients

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[PATCH] Use multiple <filein> tags for NetClients

Paolo Bonzini
... instead of a single loading script.  This requires some juggling in
the file loading order and in namespace creation, but nothing major.  It
also would make it easier 1) to automatically generate documentation for
NetClients, 2) to split separate parts of NetClients into different
packages.  Nothing of this is coming soon, but this is a good cleanup
anyway.

Paolo

packages/net:
2007-08-07  Paolo Bonzini  <[hidden email]>

        * Load.st: Delete.
        * IMAP.st: Create namespace here.
        * MIME.st: Create namespace here.
        * NNTP.st: Create namespace here.
        * POP.st: Create namespace here.
        * SMTP.st: Create namespace here.
        * FTP.st: Create namespace here.
        * HTTP.st: Create namespace here.
        * NetServer.st: Remove namespace switching.
        * URIResolver.st: Remove namespace switching.
        * Base.st: Remove namespace switching.

* comparing to [hidden email]--2004b/smalltalk--devo--2.2--patch-499
M  packages/net/package.xml
M  packages/net/IMAP.st
M  packages/net/MIME.st
M  packages/net/NNTP.st
M  packages/net/NetServer.st
M  packages/net/POP.st
M  packages/net/SMTP.st
M  packages/net/URIResolver.st
M  packages/net/Base.st
M  packages/net/FTP.st
M  packages/net/HTTP.st

* modified files

--- orig/packages/net/Base.st
+++ mod/packages/net/Base.st
@@ -36,7 +36,6 @@
 
 
 
-Namespace current: NetClients!
 NetClients at: #LineEndCR put: #cr!
 NetClients at: #LineEndLF put: #nl!
 NetClients at: #LineEndCRLF put: #crnl!
@@ -1080,7 +1079,3 @@ species
 stream
     ^stream! !
 
-
-
-
-Namespace current: Smalltalk!


--- orig/packages/net/FTP.st
+++ mod/packages/net/FTP.st
@@ -32,6 +32,7 @@
  ======================================================================"
 
 
+NetClients addSubspace: #FTP!
 Namespace current: NetClients.FTP!
 
 Object subclass:  #FTPServerEntity
@@ -510,4 +511,4 @@ fileNotFoundError: errorString
     ^FTPFileNotFoundError signal: errorString! !
 
 
-Namespace current: Smalltalk!
+Namespace current: NetClients!


--- orig/packages/net/HTTP.st
+++ mod/packages/net/HTTP.st
@@ -32,6 +32,7 @@
  ======================================================================"
 
 
+NetClients addSubspace: #HTTP!
 Namespace current: NetClients.HTTP!
 
 NetClient subclass:  #HTTPClient
@@ -409,4 +410,4 @@ parseStatusLine: aClient
     statusMessage := stream upToEnd! !
 
 
-Namespace current: Smalltalk!
+Namespace current: NetClients!


--- orig/packages/net/IMAP.st
+++ mod/packages/net/IMAP.st
@@ -31,6 +31,7 @@
 
 
 
+NetClients addSubspace: #IMAP!
 Namespace current: NetClients.IMAP!
 
 Object subclass:  #IMAPCommand
@@ -3483,4 +3484,4 @@ canParse: cmdName
 IMAPCommand initialize!
 IMAPScanner initialize!
 
-Namespace current: Smalltalk!
+Namespace current: NetClients!


--- orig/packages/net/MIME.st
+++ mod/packages/net/MIME.st
@@ -31,6 +31,7 @@
 
 
 
+NetClients addSubspace: #MIME!
 Namespace current: NetClients.MIME!
 
 Object subclass:  #MessageElement
@@ -2924,4 +2925,4 @@ printValueOn: aStream
 SimpleScanner initialize!
 RFC822Scanner initialize!
 
-Namespace current: Smalltalk!
+Namespace current: NetClients!


--- orig/packages/net/NNTP.st
+++ mod/packages/net/NNTP.st
@@ -32,6 +32,7 @@
  ======================================================================"
 
 
+NetClients addSubspace: #NNTP!
 Namespace current: NetClients.NNTP!
 
 NetClient subclass:  #NNTPClient
@@ -482,4 +483,4 @@ nextPutAll: aString
      ifFalse: [self reconnect. ex restart]]! !
 
 
-Namespace current: Smalltalk!
+Namespace current: NetClients!


--- orig/packages/net/NetServer.st
+++ mod/packages/net/NetServer.st
@@ -30,7 +30,6 @@
 |
  ======================================================================"
 
-Namespace current: NetClients!
 
 Object subclass:  #NetThread
  instanceVariableNames: 'process socket priority '
@@ -258,5 +257,3 @@ stop
     super stop.
 ! !
 
-
-Namespace current: Smalltalk!


--- orig/packages/net/POP.st
+++ mod/packages/net/POP.st
@@ -32,6 +32,7 @@
  ======================================================================"
 
 
+NetClients addSubspace: #POP!
 Namespace current: NetClients.POP!
 
 NetResponse subclass:  #POPResponse
@@ -313,4 +314,4 @@ defaultResponseClass
     ^POPResponse! !
 
 
-Namespace current: Smalltalk!
+Namespace current: NetClients!


--- orig/packages/net/SMTP.st
+++ mod/packages/net/SMTP.st
@@ -32,6 +32,7 @@
  ======================================================================"
 
 
+NetClients addSubspace: #SMTP!
 Namespace current: NetClients.SMTP!
 
 NetClient subclass:  #SMTPClient
@@ -284,4 +285,4 @@ smtpVerify: aString
     self checkResponse! !
 
 
-Namespace current: Smalltalk!
+Namespace current: NetClients!


--- orig/packages/net/URIResolver.st
+++ mod/packages/net/URIResolver.st
@@ -32,8 +32,6 @@
  ======================================================================"
 
 
-Namespace current: NetClients!
-
 Object subclass:  #URIResolver
  instanceVariableNames: 'url reporter noCache client entity '
  classVariableNames: ''


--- orig/packages/net/package.xml
+++ mod/packages/net/package.xml
@@ -2,19 +2,31 @@
   <name>NetClients</name>
   <prereq>TCP</prereq>
   <prereq>SUnit</prereq>
-  <filein>Load.st</filein>
 
+  <filein>MIME.st</filein>
+  <filein>Base.st</filein>
+  <filein>ContentHandler.st</filein>
+  <filein>IMAP.st</filein>
+  <filein>POP.st</filein>
+  <filein>SMTP.st</filein>
+  <filein>NNTP.st</filein>
+  <filein>FTP.st</filein>
+  <filein>HTTP.st</filein>
+  <filein>URIResolver.st</filein>
+  <filein>NetServer.st</filein>
+
+  <namespace>NetClients</namespace>
+
+  <file>ChangeLog</file>
   <file>Base.st</file>
-  <file>HTTP.st</file>
-  <file>Load.st</file>
-  <file>NetServer.st</file>
-  <file>MIME.st</file>
   <file>ContentHandler.st</file>
   <file>FTP.st</file>
+  <file>HTTP.st</file>
   <file>IMAP.st</file>
+  <file>MIME.st</file>
   <file>NNTP.st</file>
+  <file>NetServer.st</file>
   <file>POP.st</file>
   <file>SMTP.st</file>
   <file>URIResolver.st</file>
-  <file>ChangeLog</file>
 </package>




_______________________________________________
help-smalltalk mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/help-smalltalk