Class MsFunction
- All Implemented Interfaces:
IFunction,ISearchPath,IStatement,MsSourceStatement,IHashable
Represents a Microsoft SQL user-defined function.
Supports scalar, table-valued, and other function types.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancompare(IStatement obj) This method does not account for nested child PgStatements.voidcomputeHash(Hasher hasher) Computes the hash of the implementing object using the provided hasher.Gets the type of this database object.booleanDetermines whether this function needs to be dropped before creating the new version.voidsetFuncType(MsFunctionTypes funcType) Methods inherited from class org.pgcodekeeper.core.database.ms.schema.MsAbstractFunction
getFirstPart, getSecondPart, isAnsiNulls, isQuotedIdentified, setAnsiNulls, setFirstPart, setQuotedIdentified, setSecondPartMethods inherited from class org.pgcodekeeper.core.database.ms.schema.MsAbstractCommonFunction
addArgument, appendAlterSQL, canDropBeforeCreate, getArguments, getCreationSQL, getReturns, getReturnsColumns, setReturnsMethods inherited from class org.pgcodekeeper.core.database.ms.schema.MsAbstractStatement
appendOwnerSQL, formatSql, getQuoter, getRenameCommand, getSeparator, isOwnedMethods inherited from class org.pgcodekeeper.core.database.base.schema.AbstractStatement
addDependency, addPrivilege, appendAlterComments, appendComments, appendPrivileges, canDrop, checkComments, clearPrivileges, compareChildren, deepCopy, equals, fillChildrenList, fillDescendantsList, getAuthor, getBareName, getChildren, getComment, getDependencies, getDescendants, getDropSQL, getDropSQL, getLibName, getLocation, getName, getObjectState, getObjectState, getOwner, getParent, getPrivileges, getQualifiedName, getSQL, getTwin, hasChildren, hashCode, isLib, setAuthor, setComment, setLibName, setLocation, setOwner, setParent, shallowCopy, toStringMethods inherited from interface org.pgcodekeeper.core.database.api.schema.ISearchPath
getContainingSchema, getDatabase, getSchemaName, toObjectReferenceMethods inherited from interface org.pgcodekeeper.core.database.api.schema.IStatement
addDependency, appendAlterSQL, appendOwnerSQL, canDrop, canDropBeforeCreate, clearPrivileges, deepCopy, formatSql, getAuthor, getBareName, getChildren, getComment, getCreationSQL, getDependencies, getDescendants, getDropSQL, getLibName, getLocation, getName, getOwner, getParent, getPrivileges, getQualifiedName, getQuotedName, getQuoter, getRenameCommand, getSeparator, getSQL, getTwin, getTypeName, hasChildren, isLib, isOwned, quote, setComment, setLibName, setLocation, setOwner, shallowCopyMethods inherited from interface org.pgcodekeeper.core.database.ms.schema.MsSourceStatement
appendName, appendSourceStatement
-
Constructor Details
-
MsFunction
Creates a new Microsoft SQL function.- Parameters:
name- the function name
-
-
Method Details
-
getStatementType
Description copied from interface:IStatementGets the type of this database object.- Returns:
- the database object type
-
needDrop
Description copied from interface:IFunctionDetermines whether this function needs to be dropped before creating the new version.- Parameters:
newFunction- the new function version to compare against- Returns:
- true if the function needs to be dropped and recreated
-
computeHash
Description copied from interface:IHashableComputes the hash of the implementing object using the provided hasher. The implementation should call appropriateputmethods on the hasher for all fields that should contribute to the hash value.- Specified by:
computeHashin interfaceIHashable- Overrides:
computeHashin classMsAbstractFunction- Parameters:
hasher- the hasher instance to use for hash computation
-
compare
Description copied from class:AbstractStatementThis method does not account for nested child PgStatements. Shallow version ofAbstractStatement.equals(Object)- Specified by:
comparein interfaceIStatement- Overrides:
comparein classMsAbstractCommonFunction
-
setFuncType
-