⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 legacypropertiesconfigurationprovider.java

📁 struts 2 核心包 的源码 有错误是难免的
💻 JAVA
字号:
// Decompiled by Jad v1.5.8e2. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://kpdus.tripod.com/jad.html
// Decompiler options: packimports(3) fieldsfirst ansi space 
// Source File Name:   LegacyPropertiesConfigurationProvider.java

package org.apache.struts2.config;

import com.opensymphony.xwork2.config.*;
import com.opensymphony.xwork2.inject.*;
import com.opensymphony.xwork2.util.location.LocatableProperties;
import java.util.Iterator;
import java.util.Locale;

// Referenced classes of package org.apache.struts2.config:
//			Settings

public class LegacyPropertiesConfigurationProvider
	implements ConfigurationProvider
{

	public LegacyPropertiesConfigurationProvider()
	{
	}

	public void destroy()
	{
		Settings.reset();
	}

	public void init(Configuration configuration)
		throws ConfigurationException
	{
		Settings.reset();
	}

	public void loadPackages()
		throws ConfigurationException
	{
	}

	public boolean needsReload()
	{
		return false;
	}

	public void register(ContainerBuilder builder, LocatableProperties props)
		throws ConfigurationException
	{
		Settings settings = Settings.getInstance();
		loadSettings(props, settings);
		Settings  = settings;
		final Locale locale = Settings.getLocale();
		builder.factory(java/util/Locale, new Factory() {

			final Locale val$locale;
			final LegacyPropertiesConfigurationProvider this$0;

			public Object create(Context context)
				throws Exception
			{
				return locale;
			}

			
			{
				this$0 = LegacyPropertiesConfigurationProvider.this;
				locale = locale1;
				super();
			}
		});
	}

	protected void loadSettings(LocatableProperties props, Settings settings)
	{
		String name;
		for (Iterator i = settings.listImpl(); i.hasNext(); props.setProperty(name, settings.getImpl(name), settings.getLocationImpl(name)))
			name = (String)i.next();

	}
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -