Given:
andWhich two should the module-info file include for it to represent the service provider interface? (Choose two.)
Given:
andWhich two should the module-info file include for it to represent the service provider interface? (Choose two.)
To represent the service provider interface correctly in the module-info file, two important declarations are needed: exporting the package with the service interface and providing the implementation for the service interface. First, the package containing the service interface, 'com.transport.vehicle.cars', should be exported, which is handled by the 'exports com.transport.vehicle.cars;' statement. Second, the relationship between the service interface and its implementation needs to be specified. This is done with the 'provides com.transport.vehicle.cars.Car with com.transport.vehicle.cars.impl.CarImpl;' statement, indicating that 'CarImpl' is the provider for the 'Car' service interface.
requires must be module name only