OWL ITS + 탐지시스템(인터넷 진흥원)
jhjang
2021-12-12 5d6ea07024b475d94b997ad5972f433cf0b5aae4
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
package kr.wisestone.owl.util;
 
import org.thymeleaf.context.Context;
 
import java.util.Locale;
import java.util.Map;
 
public class StringTemplateUtil {
 
    public static Context makeContext(Map<String, Object> contents, Locale locale) {
        Context context = new Context(locale);
 
        for(String key : contents.keySet()) {
            context.setVariable(key, contents.get(key));
        }
        return context;
    }
}