All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.anotheria.anosite.gen.aswizarddata.service.ASWizardDataServiceFactory Maven / Gradle / Ivy

There is a newer version: 4.1.2
Show newest version
/**
 ********************************************************************************
 *** ASWizardDataServiceFactory.java                                          ***
 *** The factory for the IASWizardDataService implementation.                 ***
 *** generated by AnoSiteGenerator (ASG), Version: 3.2.2                      ***
 *** Copyright (C) 2005 - 2023 Anotheria.net, www.anotheria.net               ***
 *** All Rights Reserved.                                                     ***
 ********************************************************************************
 *** Don't edit this code, if you aren't sure                                 ***
 *** that you do exactly know what you are doing!                             ***
 *** It's better to invest time in the generator, as into the generated code. ***
 ********************************************************************************
 */

package net.anotheria.anosite.gen.aswizarddata.service;

import java.util.concurrent.atomic.AtomicInteger;
import net.anotheria.moskito.core.dynamic.MoskitoInvokationProxy;
import net.anotheria.moskito.core.predefined.ServiceStatsCallHandler;
import net.anotheria.moskito.core.predefined.ServiceStatsFactory;
import net.anotheria.asg.service.ASGService;
import net.anotheria.anoprise.metafactory.ServiceFactory;

public class ASWizardDataServiceFactory implements ServiceFactory{

	private static AtomicInteger instanceCounter = new AtomicInteger(0);
	private static IASWizardDataService defaultInstance = createASWizardDataService();

	public IASWizardDataService create(){
		return createASWizardDataService();
	}

	public static IASWizardDataService createASWizardDataService(){
		MoskitoInvokationProxy proxy = new MoskitoInvokationProxy(
			createInstance(),
			new ServiceStatsCallHandler(),
			new ServiceStatsFactory(),
			"IASWizardDataService-"+instanceCounter.incrementAndGet(),
			"service",
			"asg-cms",
			IASWizardDataService.class, ASGService.class
		);
		return (IASWizardDataService) proxy.createProxy();
	}

	private static IASWizardDataService createInstance(){
		return ASWizardDataServiceImpl.getInstance();
	}

	static IASWizardDataService getDefaultInstance(){
		return defaultInstance;
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy