D2065: wireprotoserver: rename abstractserverproto and improve docstring
This revision was automatically updated to reflect the committed changes. Closed by commit rHG04231e893a12: wireprotoserver: rename abstractserverproto and improve docstring (authored by indygreg, committed by ). REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D2065?vs=5299=5313 REVISION DETAIL https://phab.mercurial-scm.org/D2065 AFFECTED FILES mercurial/wireprotoserver.py CHANGE DETAILS diff --git a/mercurial/wireprotoserver.py b/mercurial/wireprotoserver.py --- a/mercurial/wireprotoserver.py +++ b/mercurial/wireprotoserver.py @@ -38,10 +38,13 @@ # to reflect BC breakages. SSHV2 = 'exp-ssh-v2-0001' -class abstractserverproto(object): -"""abstract class that summarizes the protocol API +class baseprotocolhandler(object): +"""Abstract base class for wire protocol handlers. -Used as reference and documentation. +A wire protocol handler serves as an interface between protocol command +handlers and the wire protocol transport layer. Protocol handlers provide +methods to read command arguments, redirect stdio for the duration of +the request, handle response types, etc. """ __metaclass__ = abc.ABCMeta @@ -104,7 +107,7 @@ return ''.join(chunks) -class webproto(abstractserverproto): +class webproto(baseprotocolhandler): def __init__(self, req, ui): self._req = req self._ui = ui @@ -333,7 +336,7 @@ return '' -class sshserver(abstractserverproto): +class sshserver(baseprotocolhandler): def __init__(self, ui, repo): self._ui = ui self._repo = repo To: indygreg, #hg-reviewers, durin42 Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D2065: wireprotoserver: rename abstractserverproto and improve docstring
indygreg updated this revision to Diff 5299. REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D2065?vs=5262=5299 REVISION DETAIL https://phab.mercurial-scm.org/D2065 AFFECTED FILES mercurial/wireprotoserver.py CHANGE DETAILS diff --git a/mercurial/wireprotoserver.py b/mercurial/wireprotoserver.py --- a/mercurial/wireprotoserver.py +++ b/mercurial/wireprotoserver.py @@ -38,10 +38,13 @@ # to reflect BC breakages. SSHV2 = 'exp-ssh-v2-0001' -class abstractserverproto(object): -"""abstract class that summarizes the protocol API +class baseprotocolhandler(object): +"""Abstract base class for wire protocol handlers. -Used as reference and documentation. +A wire protocol handler serves as an interface between protocol command +handlers and the wire protocol transport layer. Protocol handlers provide +methods to read command arguments, redirect stdio for the duration of +the request, handle response types, etc. """ __metaclass__ = abc.ABCMeta @@ -104,7 +107,7 @@ return ''.join(chunks) -class webproto(abstractserverproto): +class webproto(baseprotocolhandler): def __init__(self, req, ui): self._req = req self._ui = ui @@ -333,7 +336,7 @@ return '' -class sshserver(abstractserverproto): +class sshserver(baseprotocolhandler): def __init__(self, ui, repo): self._ui = ui self._repo = repo To: indygreg, #hg-reviewers, durin42 Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D2065: wireprotoserver: rename abstractserverproto and improve docstring
indygreg created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers. REVISION SUMMARY The docstring isn't completely accurate for the current state of the world. But it does describe the direction future patches will be taking things. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D2065 AFFECTED FILES mercurial/wireprotoserver.py CHANGE DETAILS diff --git a/mercurial/wireprotoserver.py b/mercurial/wireprotoserver.py --- a/mercurial/wireprotoserver.py +++ b/mercurial/wireprotoserver.py @@ -32,10 +32,13 @@ HGTYPE2 = 'application/mercurial-0.2' HGERRTYPE = 'application/hg-error' -class abstractserverproto(object): -"""abstract class that summarizes the protocol API +class baseprotocolhandler(object): +"""Abstract base class for wire protocol handlers. -Used as reference and documentation. +A wire protocol handler serves as an interface between protocol command +handlers and the wire protocol transport layer. Protocol handlers provide +methods to read command arguments, redirect stdio for the duration of +the request, handle response types, etc. """ __metaclass__ = abc.ABCMeta @@ -98,7 +101,7 @@ return ''.join(chunks) -class webproto(abstractserverproto): +class webproto(baseprotocolhandler): def __init__(self, req, ui): self._req = req self._ui = ui @@ -327,7 +330,7 @@ return '' -class sshserver(abstractserverproto): +class sshserver(baseprotocolhandler): def __init__(self, ui, repo): self._ui = ui self._repo = repo To: indygreg, #hg-reviewers Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel