本文整理了Java中org.apache.hadoop.hive.metastore.api.Function.setFunctionName()
方法的一些代码示例,展示了Function.setFunctionName()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Function.setFunctionName()
方法的具体详情如下:
包路径:org.apache.hadoop.hive.metastore.api.Function
类名称:Function
方法名:setFunctionName
暂无
代码示例来源:origin: apache/hive
@Test(expected = InvalidObjectException.class)
public void testCreateFunctionEmptyName() throws Exception {
Function function = testFunctions[0];
function.setFunctionName("");
client.createFunction(function);
}
代码示例来源:origin: apache/hive
@Test(expected = InvalidObjectException.class)
public void testCreateFunctionInvalidName() throws Exception {
Function function = testFunctions[0];
function.setFunctionName("test_function_2;");
client.createFunction(function);
}
代码示例来源:origin: apache/hive
@Test(expected = MetaException.class)
public void testCreateFunctionNullFunctionName() throws Exception {
Function function = testFunctions[0];
function.setFunctionName(null);
client.createFunction(function);
}
代码示例来源:origin: apache/hive
@Test(expected = MetaException.class)
public void testAlterFunctionNullFunctionNameInNew() throws Exception {
Function newFunction = getNewFunction();
newFunction.setFunctionName(null);
client.alterFunction(DEFAULT_DATABASE, "test_function_to_find_2", newFunction);
}
代码示例来源:origin: apache/hive
@Test(expected = MetaException.class)
public void testCreateFunctionNullFunctionType() throws Exception {
Function function = testFunctions[0];
function.setFunctionName("test_function_2");
function.setFunctionType(null);
client.createFunction(function);
}
代码示例来源:origin: apache/hive
@Test(expected = MetaException.class)
public void testAlterFunctionInvalidNameInNew() throws Exception {
Function newFunction = getNewFunction();
newFunction.setFunctionName("test_function_2;");
client.alterFunction(DEFAULT_DATABASE, "test_function_to_find_2", newFunction);
}
代码示例来源:origin: apache/hive
@Test(expected = MetaException.class)
public void testAlterFunctionEmptyNameInNew() throws Exception {
Function newFunction = getNewFunction();
newFunction.setFunctionName("");
client.alterFunction(DEFAULT_DATABASE, "test_function_to_find_2", newFunction);
}
代码示例来源:origin: apache/hive
@Test(expected = MetaException.class)
public void testCreateFunctionNullOwnerType() throws Exception {
Function function = testFunctions[0];
function.setFunctionName("test_function_2");
function.setOwnerType(null);
client.createFunction(function);
}
代码示例来源:origin: apache/hive
@Test
public void testCreateFunctionDefaultValues() throws Exception {
Function function = new Function();
function.setDbName(OTHER_DATABASE);
function.setFunctionName("test_function");
function.setClassName(TEST_FUNCTION_CLASS);
function.setOwnerType(PrincipalType.USER);
function.setFunctionType(FunctionType.JAVA);
client.createFunction(function);
Function createdFunction = client.getFunction(function.getDbName(),
function.getFunctionName());
Assert.assertNull("Comparing OwnerName", createdFunction.getOwnerName());
Assert.assertEquals("Comparing ResourceUris", 0, createdFunction.getResourceUris().size());
// The create time is set
Assert.assertNotEquals("Comparing CreateTime", 0, createdFunction.getCreateTime());
}
代码示例来源:origin: apache/hive
unsetFunctionName();
} else {
setFunctionName((String)value);
代码示例来源:origin: apache/hive
newFunction.setFunctionName("test_function_3");
client.alterFunction("DeFaUlt", "tEsT_FuncTION_HiDDEn_1", newFunction);
alteredFunction = client.getFunction(newFunction.getDbName(), newFunction.getFunctionName());
代码示例来源:origin: org.spark-project.hive/hive-metastore
unsetFunctionName();
} else {
setFunctionName((String)value);
代码示例来源:origin: com.facebook.presto.hive/hive-apache
unsetFunctionName();
} else {
setFunctionName((String)value);
代码示例来源:origin: org.apache.hive/hive-standalone-metastore
unsetFunctionName();
} else {
setFunctionName((String)value);
内容来源于网络,如有侵权,请联系作者删除!