Fixed package name and some spelling mistakes.
This commit is contained in:
parent
3ef1613fa6
commit
c312fce43b
@ -1,4 +1,4 @@
|
||||
package com.iluwater;
|
||||
package com.iluwatar;
|
||||
/**
|
||||
* Service locator pattern, used to lookup jndi services
|
||||
* and cache them for subsequent requests.
|
@ -1,4 +1,4 @@
|
||||
package com.iluwater;
|
||||
package com.iluwatar;
|
||||
|
||||
/**
|
||||
* For JNDI lookup of services from the web.xml. Will match name of the service name that
|
||||
@ -16,10 +16,10 @@ public class InitContext {
|
||||
*/
|
||||
public Object lookup(String serviceName){
|
||||
if( serviceName.equals("jndi/serviceA") ){
|
||||
System.out.println("Looking up service A and creating new serivce for A");
|
||||
System.out.println("Looking up service A and creating new service for A");
|
||||
return new ServiceImpl("jndi/serviceA");
|
||||
} else if( serviceName.equals("jndi/serviceB") ){
|
||||
System.out.println("Looking up service B and creating new serivce for B");
|
||||
System.out.println("Looking up service B and creating new service for B");
|
||||
return new ServiceImpl("jndi/serviceB");
|
||||
} else {
|
||||
return null;
|
@ -1,4 +1,4 @@
|
||||
package com.iluwater;
|
||||
package com.iluwatar;
|
||||
|
||||
/**
|
||||
* This is going to be the parent service interface which we will
|
@ -1,4 +1,4 @@
|
||||
package com.iluwater;
|
||||
package com.iluwatar;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
@ -1,4 +1,4 @@
|
||||
package com.iluwater;
|
||||
package com.iluwatar;
|
||||
|
||||
/**
|
||||
* This is a single service implementation of a sample service. This is the actual
|
@ -1,8 +1,8 @@
|
||||
package com.iluwater;
|
||||
package com.iluwatar;
|
||||
|
||||
/**
|
||||
* The service locator module.
|
||||
* Will fetch service from cache, otherwise creats a fresh service and update cache
|
||||
* Will fetch service from cache, otherwise creates a fresh service and update cache
|
||||
*
|
||||
* @author saifasif
|
||||
*
|
Loading…
x
Reference in New Issue
Block a user