src/org/jnetpcap/util/resolver/IEEEOuiPrefixResolver.java
@Override
	public void initializeIfNeeded() {
		if (initialized == false && hasCacheFile() == false) {
			initialized = true;

			setCacheCapacity(13000); // There are over 12,000 entries in the db

			super.initializeIfNeeded(); // Allow the baseclass to prep cache

			setPositiveTimeout(INFINITE_TIMEOUT); // Never
			setNegativeTimeout(0);

			/*
			 * First look for compressed OUI database.
			 */

			try {
				URL url = JConfig.getResourceURL(RESOURCE_COMPRESSED_OUI_DATABASE);
				if (url != null) {
					logger
							.fine("loading compressed database file from " + url.toString());
					readOuisFromCompressedIEEEDb(RESOURCE_COMPRESSED_OUI_DATABASE);
					return;
				}

				boolean download =
						Boolean.parseBoolean(JConfig.getProperty(PROPERTY_OUI_DB_DOWNLOAD,
								DEFAULT_OUI_DB_DOWNLOAD));
				String u = JConfig.getProperty(PROPERTY_OUI_DB_URL);
				if (u != null && download) {
					url = new URL(u);
					logger.fine("loading remote database " + url.toString());
					loadCache(url);
					return;
				}
			} catch (IOException e) {
				logger.log(Level.WARNING, "error while reading database", e);
			}
		} else {
			super.initializeIfNeeded();
		}
	}
/**
	 * Initializes the resolver by first checking if there are any cached entries,
	 * if none, it reads the compressed oui database supplied with jNetPcap in the
	 * resource directory.
	 */
Initializes the resolver by first checking if there are any cached entries,
if none, it reads the compressed oui database supplied with jNetPcap in the
resource directory.
Initializes the resolver by first checking if there are any cached entries if none it reads the compressed oui database supplied with jNetPcap in the resource directory .
@Override
	public void initializeIfNeeded() {
		if (initialized == false && hasCacheFile() == false) {
			initialized = true;
			setCacheCapacity(13000); 
			super.initializeIfNeeded(); 
			setPositiveTimeout(INFINITE_TIMEOUT); 
			setNegativeTimeout(0);
			/*
			 * First look for compressed OUI database.
			 */
			try {
				URL url = JConfig.getResourceURL(RESOURCE_COMPRESSED_OUI_DATABASE);
				if (url != null) {
					logger
							.fine("loading compressed database file from " + url.toString());
					readOuisFromCompressedIEEEDb(RESOURCE_COMPRESSED_OUI_DATABASE);
					return;
				}
				boolean download =
						Boolean.parseBoolean(JConfig.getProperty(PROPERTY_OUI_DB_DOWNLOAD,
								DEFAULT_OUI_DB_DOWNLOAD));
				String u = JConfig.getProperty(PROPERTY_OUI_DB_URL);
				if (u != null && download) {
					url = new URL(u);
					logger.fine("loading remote database " + url.toString());
					loadCache(url);
					return;
				}
			} catch (IOException e) {
				logger.log(Level.WARNING, "error while reading database", e);
			}
		} else {
			super.initializeIfNeeded();
		}
	}
@ Override public void initializeIfNeeded ( ) { if ( initialized == false && hasCacheFile ( ) == false ) { initialized = true ; setCacheCapacity ( 13000 ) ; super . initializeIfNeeded ( ) ; setPositiveTimeout ( INFINITE_TIMEOUT ) ; setNegativeTimeout ( 0 ) ; /*
			 * First look for compressed OUI database.
			 */ try { URL url = JConfig . getResourceURL ( RESOURCE_COMPRESSED_OUI_DATABASE ) ; if ( url != null ) { logger . fine ( "loading compressed database file from " + url . toString ( ) ) ; readOuisFromCompressedIEEEDb ( RESOURCE_COMPRESSED_OUI_DATABASE ) ; return ; } boolean download = Boolean . parseBoolean ( JConfig . getProperty ( PROPERTY_OUI_DB_DOWNLOAD , DEFAULT_OUI_DB_DOWNLOAD ) ) ; String u = JConfig . getProperty ( PROPERTY_OUI_DB_URL ) ; if ( u != null && download ) { url = new URL ( u ) ; logger . fine ( "loading remote database " + url . toString ( ) ) ; loadCache ( url ) ; return ; } } catch ( IOException e ) { logger . log ( Level . WARNING , "error while reading database" , e ) ; } } else { super . initializeIfNeeded ( ) ; } }
Initializes the resolver by first checking if there are any cached entries,
 if none, it reads the compressed oui database supplied with jNetPcap in the
 resource directory.
Initializes the resolver by first checking if there are any cached entries if none it reads the compressed oui database supplied with jNetPcap in the resource directory .
// There are over 12,000 entries in the db // Allow the baseclass to prep cache // Never