org.mindswap.ocl
Interface OCLCache

All Known Implementing Classes:
OCLCacheImpl

public interface OCLCache

Title:

Description: A cache for the OCL. This is responsible for caching jar files that have been loaded over the network to a directory on the local disk so that next time an object is created or executed that requires the remote jar, the local cached copy will be used instead of re-downloading the jar file.

Copyright: Copyright (c) 2005

Company: Mindswap (http://www.mindswap.org)


Method Summary
 void cache(java.net.URL theURL)
          Adds a new value at the specified url to the cache
 java.net.URL getLocalURL(java.net.URL theURL)
          Returns the local url of a cached remote url
 boolean hasFile(java.net.URL theURL)
          Checks to see if the file with the given remote url exists in the cache
 

Method Detail

hasFile

public boolean hasFile(java.net.URL theURL)
Checks to see if the file with the given remote url exists in the cache

Parameters:
theURL - URL the url to search for
Returns:
boolean true if the file is in the cache, false otherwise

getLocalURL

public java.net.URL getLocalURL(java.net.URL theURL)
Returns the local url of a cached remote url

Parameters:
theURL - URL the remote url
Returns:
URL the local, cached url of the specified file, or null if the file is not in the cache

cache

public void cache(java.net.URL theURL)
Adds a new value at the specified url to the cache

Parameters:
theURL - URL the remote url to cache