net.time4j.WeekExtension Maven / Gradle / Ivy
/*
* -----------------------------------------------------------------------
* Copyright © 2013-2015 Meno Hochschild,
* -----------------------------------------------------------------------
* This file (WeekExtension.java) is part of project Time4J.
*
* Time4J is free software: You can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation, either version 2.1 of the License, or
* (at your option) any later version.
*
* Time4J is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with Time4J. If not, see .
* -----------------------------------------------------------------------
*/
package net.time4j;
import net.time4j.engine.AttributeQuery;
import net.time4j.engine.ChronoElement;
import net.time4j.engine.ChronoEntity;
import net.time4j.engine.ChronoExtension;
import java.util.Locale;
import java.util.Set;
/**
* Wochenmodell-Erweiterung.
*
* @author Meno Hochschild
*/
class WeekExtension
implements ChronoExtension {
//~ Methoden ------------------------------------------------------
@Override
public boolean accept(Class> chronoType) {
return false; // never called
}
@Override
public Set> getElements(
Locale locale,
AttributeQuery attributes
) {
return Weekmodel.of(locale).getElements();
}
@Override
public > T resolve(
T entity,
Locale locale,
AttributeQuery attributes
) {
return entity; // no-op
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy