Interface DescriptorClassCode


public interface DescriptorClassCode
New service descriptor metadata with its class code.
  • Method Details

    • create

      static DescriptorClassCode create(ClassCode classCode, double weight, Set<ResolvedType> contracts, Set<ResolvedType> factoryContracts)
      Create a new instance.
      Parameters:
      classCode - class code that contains necessary information for the generated class.
      weight - weight of the service this descriptor describes
      contracts - contracts of the service (i.e. MyContract)
      factoryContracts - factory contracts of this service (i.e. Supplier<MyContract>)
      Returns:
      a new class code of service descriptor
    • classCode

      ClassCode classCode()
      New source code information.
      Returns:
      class code
    • weight

      double weight()
      Weight of the new descriptor.
      Returns:
      weight
    • contracts

      Set<ResolvedType> contracts()
      Contracts the described service implements/provides.
      Returns:
      contracts of the service
    • factoryContracts

      Set<ResolvedType> factoryContracts()
      Contracts of the class if it is a factory.
      Returns:
      factory contracts