GetLocation() public method

Gets the location of the resource by checking its location flags.
The resource does not have a location flag set
public GetLocation ( ) : ResourceLocation
return ResourceLocation
Beispiel #1
0
        private LoadedCache GetCache(ResourceReference resource)
        {
            LoadedCache cache;

            if (!_loadedCaches.TryGetValue(resource.GetLocation(), out cache))
            {
                throw new InvalidOperationException("The requested resource is located in " + resource.GetLocation() + ", but the corresponding cache file has not been loaded.");
            }
            return(cache);
        }
 private LoadedCache GetCache(ResourceReference resource)
 {
     LoadedCache cache;
     if (!_loadedCaches.TryGetValue(resource.GetLocation(), out cache))
         throw new InvalidOperationException("The requested resource is located in " + resource.GetLocation() + ", but the corresponding cache file has not been loaded.");
     return cache;
 }