
br.com.objectos.schema.info.LocalDateTimeColumnInfoMethodInfo Maven / Gradle / Ivy
/*
* Copyright 2015 Objectos, Fábrica de Software LTDA.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
package br.com.objectos.schema.info;
import java.time.LocalDateTime;
import br.com.objectos.code.MethodInfo;
import br.com.objectos.db.DateComparison;
import com.squareup.javapoet.TypeName;
/**
* @author [email protected] (Marcio Endo)
*/
class LocalDateTimeColumnInfoMethodInfo extends ColumnInfoMethodInfo implements LocalDateTimeColumnInfo {
private final LocalDateTimeColumnKind kind;
public LocalDateTimeColumnInfoMethodInfo(TableNameTypeInfo tableName,
MethodInfo methodInfo,
LocalDateTimeColumnKind kind) {
super(tableName, methodInfo);
this.kind = kind;
}
@Override
public LocalDateTimeColumnKind kind() {
return kind;
}
@Override
public DefaultValue defaultValue() {
return DefaultValue.unset();
}
@Override
Class> comparisonOperatorClass() {
return DateComparison.class;
}
@Override
Enum> comparisonOperatorDefaultValue() {
return DateComparison.EQ;
}
@Override
TypeName valueTypeName() {
return TypeName.get(LocalDateTime.class);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy