|
From: Schmidmeier, A. <Arn...@si...> - 2001-01-15 10:57:04
|
Hello,
OK, fine with me in general, only one small suggestion, let the static
member throw a=20
runtime-exception, which is called something like =
InvalidInvocationOrder.
Arno
> -----Urspr=FCngliche Nachricht-----
> Von: bc...@wo... [SMTP:bc...@wo...]
> Gesendet am: Freitag, 12. Januar 2001 15:42
> An: jyt...@li...
> Betreff: Re: AW: [Jython-dev] Protected Java attributes in Python
> subclasses
>=20
> [Finn]
>=20
> > (Perhaps we should consider adding a =
PythonInterpreter.initialize(..)
> > method that just calls one of the PySystemState.initialize=20
> > methods. That
> > way the initialization methods becomes more visible.)
>=20
> [Arno Schmidmeier]
>=20
> >I would suggest to add an additional constructor.
> >PythonInterpreter(Properties,Properties,String [])
>=20
> That might give the impression that you can create a new
> PythonInterpreter which will use the new values. These values can =
only
> be specified once, so I think it is better with a static method on
> PythonInterpreter like this:
>=20
> /**
> * Initialize the jython runtime. This method should only be=20
> * called once, and should be call before any other python =
objects
> * are created (including the creation of a PythonInterpreter).
> *
> * @param preProperties A set of properties. Typically
> * System.getProperties() is used.
> * @param postProperties An other set of properties. Values like
> * python.home, python.path and all other
> * values from the registry files can be
> * added to this property set. =
PostProperties
> * will override system properties and
> * registry properties.
> * @param argv Command line argument. These values =
will=20
> * assigned to sys.argv.
> */
> public static void initialize(Properties preProperties,=20
> Properties postProperties,
> String[] argv) {
> PySystemState.initialize(preProperties, postProperties, =
argv);
> }
>=20
> regards,
> finn
>=20
> _______________________________________________
> Jython-dev mailing list
> Jyt...@li...
> http://lists.sourceforge.net/lists/listinfo/jython-dev
|