1
0
mirror of https://github.com/Rogiel/l2jserver2 synced 2025-12-08 08:23:11 +00:00

Change-Id: I0000000000000000000000000000000000000000

Change-Id: Idb54de2399013c159bda588be1ce065b8314af60
Change-Id: I8b913da4fe5139078b935b99e8e1aaa091480a75
This commit is contained in:
rogiel
2011-05-04 14:22:42 -03:00
parent 9a6c0233e9
commit 81d2babede
60 changed files with 274 additions and 126 deletions

View File

@@ -51,8 +51,9 @@ public class StaticTemplateService extends AbstractService implements
}
@Override
public Template getTemplate(TemplateID id) {
return templates.get(id);
@SuppressWarnings("unchecked")
public <T extends Template> T getTemplate(TemplateID<T> id) {
return (T) templates.get(id);
}
public void addTemplate(Class<? extends Template> t) {

View File

@@ -8,11 +8,13 @@ public interface TemplateService extends Service {
/**
* Get the template assigned with <tt>id</tt>
*
* @param <T>
* the template type
* @param id
* the template id
* @return the template matching the id
* @return the template
*/
Template getTemplate(TemplateID id);
<T extends Template> T getTemplate(TemplateID<T> id);
/**
* Reload the template list.