framework/application/kernel/mem/src/main/java/org/ldp4j/application/kernel/impl/InMemoryResourceRepository.java
@Override
	public <T extends Resource> T resourceById(ResourceId id, Class<? extends T> expectedResourceClass) {
		checkNotNull(expectedResourceClass,"Expected resource class cannot be null");
		Resource found=find(id);
		if(expectedResourceClass.isInstance(found)) {
			return expectedResourceClass.cast(found);
		}
		return null;
	}
@Override
	public <T extends Resource> T resourceById(ResourceId id, Class<? extends T> expectedResourceClass) {
		checkNotNull(expectedResourceClass,"Expected resource class cannot be null");
		Resource found=find(id);
		if(expectedResourceClass.isInstance(found)) {
			return expectedResourceClass.cast(found);
		}
		return null;
	}
{@inheritDoc}