1 package com.sample.core; 2 3 import com.sample.utils.SampleUtil; 4 import com.sample.loglib.LogLib; 5 import com.sample.anotherlib.AnotherLib; 6 7 public class Core { 8 private boolean process; 9 private LogLib logLib = new LogLib(Core.class.getName()); 10 private SampleUtil sampleUtil; 11 12 public Core(boolean process, String coreName) { 13 this.process = process; 14 this.sampleUtil = new SampleUtil(coreName); 15 } 16 17 public void perform() { 18 if (!process) { 19 logLib.warn("Not processing !"); 20 } else { 21 this.sampleUtil.process(); 22 } 23 24 AnotherLib another = new AnotherLib("Core"); 25 26 another.doAnotherThing(); 27 } 28 29 } | Popular Tags |