is it even possible in java to execute a class located in a different directory??!
Printable View
is it even possible in java to execute a class located in a different directory??!
a <albert77@rocketmail.com> wrote in message
news:3a0b1648$1@news.devx.com...
>
> is it even possible in java to execute a class located in a different
directory??!
Well, first of all in Java you don't execute a class. You can execute a
method in a class, provided it's a static method, or you can execute a
method of an object, which of course belongs to a class. But if this class
is in a different directory? Sure. You just have to set up your classpath
to include that directory, and it'll work fine.
PC2
thanks Paul--a
"Paul Clapham" <pclapham@core-mark.com> wrote:
>
>a <albert77@rocketmail.com> wrote in message
>news:3a0b1648$1@news.devx.com...
>>
>> is it even possible in java to execute a class located in a different
>directory??!
>
>Well, first of all in Java you don't execute a class. You can execute a
>method in a class, provided it's a static method, or you can execute a
>method of an object, which of course belongs to a class. But if this class
>is in a different directory? Sure. You just have to set up your classpath
>to include that directory, and it'll work fine.
>
>PC2
>
>
>