# Uses of Interface
java.lang.classfile.CodeModel

Packages that use CodeModel
Package
Description
java.lang.classfile
Provides classfile parsing, generation, and transformation library.
java.lang.classfile.attribute
Provides interfaces describing `class` file attributes for the `java.lang.classfile` library.

- ## Uses of CodeModel in java.lang.classfile

  Methods in java.lang.classfile that return types with arguments of type CodeModel
  Modifier and Type
  Method
  Description
  `Optional<CodeModel>`
  MethodModel.`code()`
  Returns the body of this method, if there is one.
  Methods in java.lang.classfile with parameters of type CodeModel
  Modifier and Type
  Method
  Description
  `MethodBuilder`
  MethodBuilder.`transformCode(CodeModel code, CodeTransform transform)`
  Build the method body for this method by transforming the body of another method.

- ## Uses of CodeModel in java.lang.classfile.attribute

  Subinterfaces of CodeModel in java.lang.classfile.attribute
  Modifier and Type
  Interface
  Description
  `interface`
  `CodeAttribute`
  Models the `Code` attribute (JVMS 4.7.3), which contains the bytecode of this method.