Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 /*
  * Copyright (C) 2012 Clarion Media, LLC
  * 
  * 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 com.clarionmedia.infinitum.orm.persistence;

This interface provides runtime resolution of data types for the purpose of persistence in the ORM.

Author(s):
Tyler Treat
Version:
1.0 05/17/12
public interface TypeResolutionPolicy {
	// Represent the data types used in SQLite
	public static enum SqliteDataType {
		NULL, INTEGER, REAL, TEXT, BLOB
	};

Indicates if the given ID is a valid value for the given primary key java.lang.reflect.Field. Precondition assumes pkField is in fact a primary key.

Parameters:
pkField the primary key Field
id the primary key value to check
Returns:
true if it is a valid primary key value, false if not
	boolean isValidPrimaryKey(Field pkFieldSerializable id);

Indicates if the given java.lang.Class is a registered domain model for this application.

Parameters:
c the Class to check
Returns:
true if it is a domain model, false if not
	boolean isDomainModel(Class<?> c);

Indicates if the given java.lang.Class is a proxy for a domain model.

Parameters:
c the Class to check
Returns:
true if it is a domain proxy, false if not
	boolean isDomainProxy(Class<?> c);
New to GrepCode? Check out our FAQ X