This example is Perl; it's the standard DirHandle module. I've cut out the code, so you'll have to trust me on the parameters.
ProgramListing version:
package DirHandle;
require 5.000;
use Carp;
use Symbol;
sub new {
}
ClassSynopsis version:
package DirHandle; @ISA = (superclass1, superclass2); require 5.000; use Carp; use Symbol;sub new { ... };sub DESTROY { ... };
This example is IDL from the DOM spec.
ProgramListing version:
interface Element : Node {
readonly attribute DOMString tagName;
DOMString getAttribute(in DOMString name);
void setAttribute(in DOMString name,
in DOMString value)
raises(DOMException);
};
ClassSynopsis version:
interface Element: Node�{��readonly�attribute�DOMString�tagName�;DOMString�getAttribute(in�DOMString�name);void�setAttribute(in�DOMString�name, in�DOMString�value) ����raises(DOMException);}
public�TextFileWriter extends Superclass1, Superclass2 ����implements Interface1, Interface2 ����throws Exception1, Exception2�{��private�Writer�writer�;��public�String�writerName�=�"MyWriter";static�public�void�write(ResultTreeFragment�frag, ���������������������������String�file) ����throws�Exception1, Exception2;}
class Rectangle_with_data: virtual Shape, virtual Data_container
{
...
};
ClassSynopsis version:
Rectangle_with_data: virtual�Shape, virtual�Data_container�{ ...}