Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

import java.util.Map;

public class Main {
    public static final ThreadLocal<Map<String, Object>> threadCacheHolder = new ThreadLocal();

    public static Object get(String key) {
        Map<String, Object> threadCache = threadCacheHolder.get();

        if (threadCache == null) {
            return null;
        }

        return threadCache.get(key);
    }
}