class Fabric8PodLabelsAndAnnotationsSupplier implements Function<String, PodLabelsAndAnnotations> {

	private final KubernetesClient client;

	private final String namespace;

	private Fabric8PodLabelsAndAnnotationsSupplier(KubernetesClient client, String namespace) {
		this.client = client;
		this.namespace = namespace;
	}

	/**
	 * to be used when .spec.type of the Service is != 'ExternalName'.
	 */
	static Fabric8PodLabelsAndAnnotationsSupplier nonExternalName(KubernetesClient client, String namespace) {
		return new Fabric8PodLabelsAndAnnotationsSupplier(client, namespace);
	}

	/**
	 * to be used when .spec.type of the Service is == 'ExternalName'.
	 */
	static Fabric8PodLabelsAndAnnotationsSupplier externalName() {
		return new Fabric8PodLabelsAndAnnotationsSupplier(null, null);
	}

	@Override
	public PodLabelsAndAnnotations apply(String podName) {<FILL_FUNCTION_BODY>}

}

		ObjectMeta metadata = Optional.ofNullable(client.pods().inNamespace(namespace).withName(podName).get())
				.map(Pod::getMetadata).orElse(new ObjectMeta());
		return new PodLabelsAndAnnotations(metadata.getLabels(), metadata.getAnnotations());
	
<no_super_class>