Initializes the cache.
498812
protected void initialize(ClassTraversal traversal) {
    Listener 	listener;

    listener = new Listener();
    traversal.traverse(listener);

    m_NameCache = listener.getNameCache();
  }
716634
public static void initialize()
    {
        if (InfinispanCache.get().exists(AccessCache.PERMISSIONCACHE)) {
            InfinispanCache.get().<UUID, AccessType>getCache(AccessCache.PERMISSIONCACHE).clear();
        } else {
            InfinispanCache.get().<UUID, AccessType>getCache(AccessCache.PERMISSIONCACHE)
                            .addListener(new CacheLogListener(AccessCache.LOG));
        }
        if (InfinispanCache.get().exists(AccessCache.STATUSCACHE)) {
            InfinispanCache.get().<Long, AccessType>getCache(AccessCache.STATUSCACHE).clear();
        } else {
            InfinispanCache.get().<Long, AccessType>getCache(AccessCache.STATUSCACHE)
                            .addListener(new CacheLogListener(AccessCache.LOG));
        }
    }
597067
public static void initialize()
        throws CacheReloadException
    {
        if (InfinispanCache.get().exists(BundleMaker.NAMECACHE)) {
            InfinispanCache.get().<UUID, Type>getCache(BundleMaker.NAMECACHE).clear();
            InfinispanCache.get().<UUID, Type>getCache(BundleMaker.CACHE4BUNDLE).clear();
            InfinispanCache.get().<UUID, Type>getCache(BundleMaker.CACHE4BUNDLEMAP).clear();
        } else {
            InfinispanCache.get().<UUID, Type>getCache(BundleMaker.NAMECACHE)
                            .addListener(new CacheLogListener(BundleMaker.LOG));
            InfinispanCache.get().<UUID, Type>getCache(BundleMaker.CACHE4BUNDLE)
                            .addListener(new CacheLogListener(BundleMaker.LOG));
            InfinispanCache.get().<UUID, Type>getCache(BundleMaker.CACHE4BUNDLEMAP)
                            .addListener(new CacheLogListener(BundleMaker.LOG));
        }
    }
625192
def init_cache():
    '''
    
    '''
    cache_obj = json.loads("{}")
    try:
        with open(CACHE_NAME, 'r') as cache_file:
            try:
                cache_obj = json.load(cache_file)
            except ValueError:
                print("The cache file seems to be empty, starting with flushed cache")
    except IOError:
        print("The cache file seems to be empty, starting with flushed cache")

    print("Loaded JSON cache")

    return cache_obj
1076437
private function initialize()
    {
        $this->cacheDriver = $this->configuration->getMetadataCacheImpl();
        $this->driver = $this->configuration->getMetadataDriverImpl();

        if (null === $this->evm) {
            $this->evm = new EventManager();
        }
        
        $this->initialized = true;
    }
189417
protected void initCacheObject() {

        CmsImageCacheHelper helper = new CmsImageCacheHelper(getCms(), false, false, true);
        setKeys("" + helper.getFilesCount());
        setVariations("" + helper.getVariationsCount());
        setCurSize(CmsFileUtil.formatFilesize(helper.getVariationsSize(), getLocale()));
    }
872227
protected function initialize()
    {
        $this->context = $this->environment->getContext();

        if ($this->hasFrozenCacheInProduction()) {
            $this->classReflectionData = $this->reflectionDataRuntimeCache->get('__classNames');
            $this->annotatedClasses = $this->reflectionDataRuntimeCache->get('__annotatedClasses');
            $this->loadFromClassSchemaRuntimeCache = true;
        } else {
            $this->loadClassReflectionCompiletimeCache();
        }

        $this->annotationReader = new AnnotationReader();
        foreach ($this->settings['ignoredTags'] as $tagName => $ignoreFlag) {
            if ($ignoreFlag === true) {
                AnnotationReader::addGlobalIgnoredName($tagName);
            }
        }

        $this->initialized = true;
    }
913250
public static void initialize()
    {
        if (InfinispanCache.get().exists(MsgPhrase.UUIDCACHE)) {
            InfinispanCache.get().<UUID, MsgPhrase>getCache(MsgPhrase.UUIDCACHE).clear();
        } else {
            InfinispanCache.get().<UUID, MsgPhrase>getCache(MsgPhrase.UUIDCACHE)
                            .addListener(new CacheLogListener(MsgPhrase.LOG));
        }
        if (InfinispanCache.get().exists(MsgPhrase.IDCACHE)) {
            InfinispanCache.get().<Long, MsgPhrase>getCache(MsgPhrase.IDCACHE).clear();
        } else {
            InfinispanCache.get().<Long, MsgPhrase>getCache(MsgPhrase.IDCACHE)
                            .addListener(new CacheLogListener(MsgPhrase.LOG));
        }
        if (InfinispanCache.get().exists(MsgPhrase.NAMECACHE)) {
            InfinispanCache.get().<String, MsgPhrase>getCache(MsgPhrase.NAMECACHE).clear();
        } else {
            InfinispanCache.get().<String, MsgPhrase>getCache(MsgPhrase.NAMECACHE)
                            .addListener(new CacheLogListener(MsgPhrase.LOG));
        }
        if (InfinispanCache.get().exists(MsgPhrase.LABELCACHE)) {
            InfinispanCache.get().getCache(MsgPhrase.LABELCACHE).clear();
        } else {
            InfinispanCache.get().<String, String>getCache(MsgPhrase.LABELCACHE)
                            .addListener(new CacheLogListener(MsgPhrase.LOG));
        }
        if (InfinispanCache.get().exists(MsgPhrase.ARGUMENTCACHE)) {
            InfinispanCache.get().getCache(MsgPhrase.ARGUMENTCACHE).clear();
        } else {
            InfinispanCache.get().<String, List<String>>getCache(MsgPhrase.ARGUMENTCACHE)
                            .addListener(new CacheLogListener(MsgPhrase.LOG));
        }
    }
1300315
private static void initCaches() {

        if (m_cacheTemporary == null) {
            m_cacheTemporary = CmsMemoryMonitor.createLRUCacheMap(1024);

            m_cachePermanent = new ConcurrentHashMap<String, byte[]>(32);

            m_cacheContentDefinitions = CmsMemoryMonitor.createLRUCacheMap(CONTENT_DEFINITION_CACHE_SIZE);
        }
        if (OpenCms.getRunLevel() > OpenCms.RUNLEVEL_1_CORE_OBJECT) {
            if ((OpenCms.getMemoryMonitor() != null)
                && !OpenCms.getMemoryMonitor().isMonitoring(CmsXmlEntityResolver.class.getName() + ".cacheTemporary")) {
                // reinitialize the caches after the memory monitor is set up
                Map<String, byte[]> cacheTemporary = CmsMemoryMonitor.createLRUCacheMap(128);
                cacheTemporary.putAll(m_cacheTemporary);
                m_cacheTemporary = cacheTemporary;
                OpenCms.getMemoryMonitor().register(
                    CmsXmlEntityResolver.class.getName() + ".cacheTemporary",
                    cacheTemporary);

                Map<String, byte[]> cachePermanent = new ConcurrentHashMap<String, byte[]>(32);
                cachePermanent.putAll(m_cachePermanent);
                m_cachePermanent = cachePermanent;
                OpenCms.getMemoryMonitor().register(
                    CmsXmlEntityResolver.class.getName() + ".cachePermanent",
                    cachePermanent);

                Map<String, CmsXmlContentDefinition> cacheContentDefinitions = CmsMemoryMonitor.createLRUCacheMap(
                    CONTENT_DEFINITION_CACHE_SIZE);
                cacheContentDefinitions.putAll(m_cacheContentDefinitions);
                m_cacheContentDefinitions = cacheContentDefinitions;
                OpenCms.getMemoryMonitor().register(
                    CmsXmlEntityResolver.class.getName() + ".cacheContentDefinitions",
                    cacheContentDefinitions);
            }
        }
    }
556546
protected function _initCache()
    {
        if (!Cache::getConfig(static::$cacheConfig)) {
            Cache::setConfig(static::$cacheConfig, [
                'className' => $this->_getDefaultCacheConfigClassName(),
                'prefix' => static::$cacheConfig . '_' . $this->_identifier,
                'duration' => $this->getConfig('interval'),
            ]);
        }
    }
223148
public static void init(Context context, String name, int version, int cacheSize) {
		init(context, name, version, cacheSize, LogLevel.NONE);
	}
1323142
private void init()
    {
        jdbcProperties = new Properties();
        dbcpProperties = new Properties();
        setFetchSize(0);
        this.setTestOnBorrow(true);
        this.setTestOnReturn(false);
        this.setTestWhileIdle(false);
        this.setLogAbandoned(false);
        this.setRemoveAbandoned(false);
    }
52211
public function init() {

        parent::init();

        $this->autoload	= ( !empty( $this->autoloadUrl ) && CoreProperties::getInstance()->isAutoLoad() ) ? true : false;

		$this->cache = $this->cache ? $this->cache : CacheProperties::getInstance()->isCaching();
    }
448022
protected function init() {		
	    if(Apc::isAvailable()) {
		    $driver = new Apc();
		} else {
			if (!is_dir(WT_DATA_DIR.DIRECTORY_SEPARATOR.'cache')) {
				// We may not have permission - especially during setup, before we instruct
				// the user to "chmod 777 /data"
				@mkdir(WT_DATA_DIR.DIRECTORY_SEPARATOR.'cache');
			}
			if (is_dir(WT_DATA_DIR.DIRECTORY_SEPARATOR.'cache')) {
			    $driver = new FileSystem(array('path' => WT_DATA_DIR.DIRECTORY_SEPARATOR.'cache'));
			} else {
				// No cache available, let's just use a basic one :-(
				$driver = new Ephemeral();
			}
		}		

		$this->cache = new \Stash\Pool($driver);		
		$this->is_init = true;
	}
412783
private void initialise() {
        Stopwatch stopwatch = new Stopwatch();
        stopwatch.start();
        populateCache();
        stopwatch.stop();
        log.info("Cache populated. Time taken {}", stopwatch);
    }
559304
public void init() {
		if (initDepth.get() == null) {
			initDepth.set(1);
		} else {
			initDepth.set(initDepth.get() + 1);
		}

		if (resourceCache.get() == null) {
			resourceCache.set(new HashMap<String, Object>());
		}

		if (cacheLocked.get() == null) {
			cacheLocked.set(Boolean.FALSE);
		}
	}
866725
public void initialize(final Class<?> _initializer)
    {
        this.initializer = _initializer.getName();
        synchronized (this) {
            try {
                readCache();
            } catch (final CacheReloadException e) {
                AbstractCache.LOG.error("Unexpected error while initializing Cache for " + getClass(), e);
            }
        }
    }