IfmxCalendarPattern 类实现 IfmxCalendarPatternUDT TimeSeries 接口。接口提供对属于类的方法和任何常量的抽象描述。IfmxCalendarPatternUDT 接口指定任何日历模式类可能需要使用的标准常量。接口旨在仅供要开发日历模式类的程序员使用。
IfmxCalendarPattern() IfmxCalendarPattern(String pat) throws SQLException
当您从数据库选择日历模式时,会使用 getObject 方法从结果集抽取日历模式。GBase 8s JDBC Driver 使用第一个构造函数 IfmxCalendarPattern() 来实例化新 IfmxCalendarPattern 对象。它会创建未初始化任何变量的空对象。
当您在客户机上创建日历模式来插入到数据库时,可使用第二个构造函数来实例化对象。此构造函数通过解析输入字符串来对新对象进行初始化。字符串的格式是:{pattern specification}, interval:例如,{5 on, 2 off}, day。
方法 | 特征符 | 描述 |
---|---|---|
getInterval | public byte getInterval() throws SQLException | 返回日历模式时间间隔。 |
getIntervalStr | public String getIntervalStr() throws SQLException | 返回日历模式时间间隔的字符串表示法。有效值是:
|
getSQLTypeName | public String getSQLTypeName() | 返回对象的 SQL 类型名称:在这种情况下,为日历模式。 |
readSQL | public void readSQL(SQLInput stream String type) | GBase 8s JDBC Driver 自动调用来从二元结果集流初始化 IfmxCalendarPattern 对象。 |
toString | public String toString() | 返回此日历模式对象的字符串表示法。 |
writeSQL | public void writeSQL(SQLOutput stream) | 当调用 setObject 方法来将 IfmxCalendarPattern 对象插入到要发送到数据库服务器的预编译语句时,由 GBase 8s JDBC Driver 自动调用。 |