Du kannst nicht mehr als 25 Themen auswählen Themen müssen mit entweder einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

reflection.xml 1.1KB

123456789101112131415161718192021222324252627282930
  1. <chapter id="reflection" xreflabel="Reflection">
  2. <title>New Reflection Interfaces</title>
  3. <para>
  4. AspectJ 5 provides a full set of reflection APIs analogous to the
  5. <literal>java.lang.reflect</literal> package, but fully aware of the
  6. AspectJ type system. See the javadoc for the runtime and tools APIs
  7. for the full details. The reflection APIs are only supported when
  8. running under Java 5 and for code compiled by the AspectJ 5 compiler
  9. at target level 1.5.
  10. </para>
  11. <sect1 id="reflection_api">
  12. <title>Using AjTypeSystem</title>
  13. <para>
  14. The starting point for using the reflection apis is
  15. <literal>org.aspectj.lang.reflect.AjTypeSystem</literal> which
  16. provides the method <literal>getAjType(Class)</literal> which will
  17. return the <literal>AjType</literal> corresponding to a given
  18. Java class. The <literal>AjType</literal> interface corresponds to
  19. <literal>java.lang.Class</literal> and gives you access to all of the
  20. method, field, constructor, and also pointcut, advice, declare
  21. statement and inter-type declaration members in the type.
  22. </para>
  23. </sect1>
  24. </chapter>