private static Task <IResource> PointingResourceInitializer( ITypedEntity resource, IHydraClient client, ProcessingState processingState, CancellationToken cancellationToken) { resource.Unwrap().SetProperty(ResourceExtensions.BaseUrlPropertyInfo, (Uri)processingState.BaseUrl); return(ResourceInitializer(resource.ActLike <IHydraResource>(), client, processingState, cancellationToken)); }
private static Task <IResource> ClientInitializer( ITypedEntity resource, IHydraClient client, ProcessingState processingState, CancellationToken cancellationToken) { resource.Unwrap().SetProperty(ClientPropertyInfo, client); return(ResourceInitializer( resource.Is(hydra.ApiDocumentation) ? (ITypedEntity)resource.ActLike <IApiDocumentation>() : resource.ActLike <ICollection>(), client, processingState, cancellationToken)); }