Hi Patrick,
----- Original Message -----
From: "Patrick M." <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, December 31, 2002 3:01 AM
Subject: Repository runtime creation
Hello,
Is it possible to create and parse a repository at run time without
having the
compiled classes in the classpath ?
#####
In current CVS there is new Metadata-Handling.
There are no test cases at the moment, anyhow it should be
possible to create Metadata instances at runtime. But in most
many cases the classes has to reside in classpath, or you have to
set 'null'. If we don't check the existence of classes in the metadata,
this could lead to corrupt metadata at runtime.
I would like to create a repository
object at runtime and then generate the corresponding java sources from
it...
#####
It this is not possible only handle with "String" objects.
Currently you have to build your own Property based metadata.
regards,
Armin
EG:
DescriptorRepository dr = DescriptorRepository.getDefaultInstance();
ClassDescriptor cd = rd.getDescriptorFor("A");
cd.getObjectReferenceDescriptorByName("B");
getObjectReferenceDescriptorByName throws a "ClassNotFoundException" if
the
class A is not in the classpath (same with getCollectionDescriptorByName
but
ok with field descriptor)
Thanks
Patrick M.
--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>