Google Data APIs Client Library (1.41.1)



com.google.gdata.data.youtube
Class FormUploadToken

java.lang.Object
  extended by com.google.gdata.data.youtube.FormUploadToken

public class FormUploadToken
extends java.lang.Object

Answer to a 'get upload token' request.


Constructor Summary
FormUploadToken(java.lang.String url, java.lang.String token)
          Creates a form-upload token.
 
Method Summary
 java.lang.String getToken()
          Returns a token to include in the form upload.
 java.lang.String getUrl()
          Returns the url to which the form upload should be sent.
static FormUploadToken parse(java.io.InputStream input)
          Parse a form-upload token from its XML definition.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FormUploadToken

public FormUploadToken(java.lang.String url,
                       java.lang.String token)
Creates a form-upload token.

Parameters:
url - the url to which the upload should be sent
token - token data to include in the upload
Method Detail

getUrl

public java.lang.String getUrl()
Returns the url to which the form upload should be sent.

Returns:
a url that accepts POST of type multipart/form-data.

getToken

public java.lang.String getToken()
Returns a token to include in the form upload.

Parameters:
token - token data to include in the multipart/form-data upload under the name 'token'.

parse

public static FormUploadToken parse(java.io.InputStream input)
                             throws ParseException,
                                    java.io.IOException
Parse a form-upload token from its XML definition.

Parameters:
input - InputStream of server response
Throws:
ParseException
java.io.IOException