Talk About Network



Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Modula 3 > Modula 3.1 -- J...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 1 Topic 56 of 148
Post > Topic >>

Modula 3.1 -- Java-style interfaces possible syntax

by leeo@[EMAIL PROTECTED] (S. Lee Odegard) Aug 25, 2003 at 03:47 PM

I would envision internal interfaces to be of the following form. 
Elements in the PROPS section could either be implemented by
compatible fields or properties in an implementing type.  --leeo



INTERFACE MicrosoftNETPrototype;

IFACE ICloneable= IMPLEMENTS METHODS Clone(): ROOT END;

  IEnumerable= IMPLEMENTS METHODS GetEnumerator(): IEnumerator END;

  IEnumerator= IMPLEMENTS PROPS
Current: ROOT RAISES{ InvalidOperatorException };
    METHODS
MoveNext(): BOOLEAN RAISES{ InvalidOperatorException };
Reset() RAISES { InvalidOperatorException };
    END;

  ICollection= IMPLEMENTS IEnumerator PROPS
Count: INTEGER;
IsSynchronized: BOOLEAN;
SyncRoot: MUTEX;
    METHODS
CopyTo( array: ARRAY;  index: INTEGER ) RAISES {
ArgumentNullException,
      ArgumentOutOfRangeException, ArgumentException,
InvalidCastException };
    END;
END.




 1 Posts in Topic:
Modula 3.1 -- Java-style interfaces possible syntax
leeo@[EMAIL PROTECTED] (  2003-08-25 15:47:17 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Thu May 15 0:11:35 CDT 2008.