close Warning: Can't synchronize with repository "(default)" (Unsupported version control system "svn": No module named svn). Look in the Trac log for more information.

Version 111 (modified by malte.appeltauer, 10 years ago) (diff)



JCop is a context-oriented programming (COP) extension to the Java programming language. It combines COP features - introduced by its predecessor ContextJ - with new constructs for declarative and event-based layer composition and a first-class event-based context representation.

Modularization. Behavioral variations are modularized by layers that can either be defined within classes (layer-in-class) or in dedicated top-level modules (class-in-layer). Layers contain partial method definitions that extend or replace a plain method while their layers are active.

Dynamic Composition. JCop provides control-flow specific layer composition as known from other COP languages. In addition, it offers declarative composition statements that are specified within context modules and thus combines COP with concepts of aspect-oriented programming.


JVM 1.5
latest version please note recent language changes
sample programs
  • A JVM 1.5 or higher must be installed on the system.
  • Unpack the JCop archive in any directory. The archive contains
    • jcop.jar, executable archive that contains the JCop compiler
    • some AspectJ libraries that are required for compiling and/or launching JCop applications
      • aspectjtools.jar, aspectjrt.jar (required for compilation)
      • aspectjweaver.jar (required for VM instrumentation at runtime)
    • jcopc and jcop scripts for compilation and launching of JCop applications (Windows and Linux)
      (If you encounter problems using these scripts, you can use the underlying Java commands for compiling and launching applications.)
    • agg_V165_classes.jar, AGG library required to generate an AGG graph instead of bytecode.
  • The compiler requires a JCOP_HOME environment variable pointing to the directory in which the above archives and scripts are located. For convenience, the folder should also be added to the path variable to ease the access to the command scripts.


A manual describing command line options and more usage details can be found here.

Contact and Publications

For more information, please see our publications related to the JCop and ContextJ project or contact us: