Oracle® Calendar Web Services Java API Reference
10g Release 1 (10.1.1)

B14475-01


oracle.calendar.soap.client
Class CalendarUtils

java.lang.Object
  extended byoracle.calendar.soap.client.CalendarUtils


public class CalendarUtils
extends java.lang.Object

Provides some methods required for generating and processing Calendarlet methods.


Constructor Summary
CalendarUtils()
Default constructor; not used.

Method Summary
static BasicChallenge getBasicChallenge(java.util.Vector in_elements)
Returns a BasicChallenge object with information from the SOAP header.
static java.util.Calendar getCalendarFromUTC(java.lang.String in_utcTime)
Converts a UTC time string to a Java Calendar object.
static java.util.Calendar getCalendarFromUTC(java.lang.String in_utcTime, java.util.TimeZone in_tz)
Converts a UTC time string and local TimeZone to a Java Calendar object version 2003-09-05 fix009580
static java.lang.String getDate(java.util.Calendar in_date)
Retrieves the date string from a Java Calendar object.
static java.lang.String getDateRangeQuery(java.util.Calendar in_startDate, java.util.Calendar in_endDate)
Constructs a date range query that can be used for a Where clause in a vQuery.
static java.lang.String getDateRangeQueryFromLocalCal(java.util.Calendar in_startDate, java.util.Calendar in_endDate)
Constructs a date range query that can be used for a Where clause in a vQuery from a local Calendar.
static java.lang.String getReceiveBuffer(org.apache.soap.messaging.Message in_message)
Retrieves the receive buffer from a TCP/IP message.
static java.lang.String getSendBuffer(org.apache.soap.messaging.Message in_message)
Retrieves the send buffer from a TCP/IP message.
static org.apache.soap.Fault getSOAPFault(java.util.Vector in_elements)
Retrieves a SOAP fault that was returned in the Calendarlet response.
static java.lang.String getTimestamp()
Retrieves the current date and time timestamp in UTC.
static java.util.Calendar getToday()
Retrieves the Calendar object with today's date and the local time zone set.
static java.util.Calendar getToday(java.util.TimeZone in_tz)
Retrieves the Calendar object with today's date and the local time zone set.
static java.lang.String getUTCDate(java.util.Calendar in_date)
Retrieves the UTC date string from a Java Calendar object.
static java.lang.String getUTCDateTime(java.util.Calendar in_date)
Retrieves the UTC date time string from a Java Calendar object, converted from the local time zone if required.
static boolean isBasicChallenge(java.util.Vector in_elements)
Utility method that helps determine if a BasicChallenge was returned in the SOAP header.
static boolean isSOAPFault(java.util.Vector in_elements)
Determines whether or not a SOAP fault was returned in the Calendarlet response.

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

CalendarUtils

public CalendarUtils()
Default constructor; not used. version 2002-12-16 fix008343

Method Detail

isSOAPFault

public static boolean isSOAPFault(java.util.Vector in_elements)
Determines whether or not a SOAP fault was returned in the Calendarlet response. Call this method with the Vector of body elements from the Calendar response class. version 2002-12-16 fix008343
Parameters:
in_elements - Vector of XML elements
Returns:
boolean - true if a SOAP fault was returned
See Also:
CalendaringResponse.getBodyEntries()

getSOAPFault

public static org.apache.soap.Fault getSOAPFault(java.util.Vector in_elements)
                                          throws java.lang.Exception
Retrieves a SOAP fault that was returned in the Calendarlet response. Call this method with the Vector of body elements from the Calendar response class. A new Fault object will be created each time this method is called. version 2002-12-16 fix008343
Parameters:
in_elements - Vector of XML elements
Returns:
Fault - SOAP Fault
Throws:
java.lang.Exception
See Also:
CalendaringResponse.getBodyEntries()

isBasicChallenge

public static boolean isBasicChallenge(java.util.Vector in_elements)
Utility method that helps determine if a BasicChallenge was returned in the SOAP header. The input elements Vector is from the CalendaringReponse object's getHeaderEntries method. version 2002-12-16 fix008343
Parameters:
in_elements - Vector of XML elements
Returns:
boolean - true for a BasicChallenge
See Also:
CalendaringResponse.getHeaderEntries()

getBasicChallenge

public static BasicChallenge getBasicChallenge(java.util.Vector in_elements)
                                        throws java.lang.Exception
Returns a BasicChallenge object with information from the SOAP header. The input elements Vector is from the CalendaringReponse object's getHeaderEntries method. version 2002-12-16 fix008343
Parameters:
in_elements - Vector of XML elements
Returns:
BasicChallenge - new basic challenge object
Throws:
java.lang.Exception
See Also:
CalendaringResponse.getHeaderEntries()

getSendBuffer

public static java.lang.String getSendBuffer(org.apache.soap.messaging.Message in_message)
Retrieves the send buffer from a TCP/IP message. This is used internally by the Calendarlet class. version 2002-12-16 fix008343
Parameters:
in_message - TCP/IP message
Returns:
String - HTTP buffer contents

getReceiveBuffer

public static java.lang.String getReceiveBuffer(org.apache.soap.messaging.Message in_message)
Retrieves the receive buffer from a TCP/IP message. This is used internally by the Calendarlet class. version 2002-12-16 fix008343
Parameters:
in_message - TCP/IP message
Returns:
String - HTTP buffer contents

getUTCDateTime

public static java.lang.String getUTCDateTime(java.util.Calendar in_date)
Retrieves the UTC date time string from a Java Calendar object, converted from the local time zone if required.

The UTC date and time string is compatible with the iCal standard.

version 2003-02-13 fix008515
Parameters:
in_date - date object
Returns:
String - UTC string

getDate

public static java.lang.String getDate(java.util.Calendar in_date)
Retrieves the date string from a Java Calendar object. Only the date portion of the Calendar object is used. There is no time zone conversion.

The date string is compatible with the iCal standard.

version 2004-11-18 fix011194
Parameters:
in_date - date object
Returns:
String - iCal date string

getUTCDate

public static java.lang.String getUTCDate(java.util.Calendar in_date)
Retrieves the UTC date string from a Java Calendar object. Only the date portion of the Calendar object is used. There is no time zone conversion.

The UTC date string is compatible with the iCal standard.

version 2003-03-13 fix008515
Parameters:
in_date - date object
Returns:
String - UTC string

getToday

public static java.util.Calendar getToday()
Retrieves the Calendar object with today's date and the local time zone set. The time string in UTC would be yyyyMMddTXX0000Z (today's date at midnight local) where XX is the offset to GMT. version 2003-02-13 fix008515
Returns:
Calendar - Calendar object with today's date

getTimestamp

public static java.lang.String getTimestamp()
Retrieves the current date and time timestamp in UTC. The time string in UTC would be yyyyMMddThhmmssZ. version 2003-09-11 fix009594
Returns:
Calendar - Calendar object with the current date and time

getToday

public static java.util.Calendar getToday(java.util.TimeZone in_tz)
Retrieves the Calendar object with today's date and the local time zone set. The date and time time string in UTC would be yyyyMMddTXX0000Z (today's date at midnight local) where XX is the offset to GMT. version 2003-09-05 fix009580
Parameters:
in_tz - local TimeZone object
Returns:
Calendar - Calendar object with today's date

getDateRangeQuery

public static java.lang.String getDateRangeQuery(java.util.Calendar in_startDate,
                                                 java.util.Calendar in_endDate)
Constructs a date range query that can be used for a Where clause in a vQuery. The vQuery will be of the form DTEND >= 'start date' AND DTSTART <= 'end date'. version 2003-01-17 fix008443
Parameters:
in_startDate - start date for vQuery
in_endDate - end date for vQuery
Returns:
String - vQuery Where clause
See Also:
vQuery

getDateRangeQueryFromLocalCal

public static java.lang.String getDateRangeQueryFromLocalCal(java.util.Calendar in_startDate,
                                                             java.util.Calendar in_endDate)
Constructs a date range query that can be used for a Where clause in a vQuery from a local Calendar. The vQuery will be of the form DTEND >= 'start date' AND DTSTART <= 'end date'. version 2003-09-05 fix009580
Parameters:
in_startDate - start date for vQuery
in_endDate - end date for vQuery
Returns:
String vQuery Where clause
See Also:
vQuery

getCalendarFromUTC

public static java.util.Calendar getCalendarFromUTC(java.lang.String in_utcTime)
Converts a UTC time string to a Java Calendar object. version 2003-03-21 fix008832
Parameters:
in_utcTime - UTC date time string
Returns:
Calendar - Calendar object

getCalendarFromUTC

public static java.util.Calendar getCalendarFromUTC(java.lang.String in_utcTime,
                                                    java.util.TimeZone in_tz)
Converts a UTC time string and local TimeZone to a Java Calendar object version 2003-09-05 fix009580
Parameters:
in_utcTime - UTC date and time string
in_tz - local TimeZone object
Returns:
Calendar - Calendar object

Oracle® Calendar Web Services Java API Reference
10g Release 1 (10.1.1)

B14475-01


Copyright © 1998, 2005, Oracle. All rights reserved.