com.skype
Class Profile

java.lang.Object
  extended by com.skype.Profile

public final class Profile
extends Object

The Profile class contains the current user's information.

For example, you can get the mood message of the current user by this code:

String moodMessage = Skype.getProfile().getMoodMessage();
And you can change it by the following code:
Skype.getProfile().setMoodMessage("Happy!");

Author:
Koji Hisano

Nested Class Summary
static class Profile.CallForwardingRule
          The CallForwardingRule class contains the information of a call forwarding rule.
static class Profile.Sex
          The Sex enum contains the sex constants of the current user.
static class Profile.Status
          The Status enum contains the online status constants of the current user.
 
Field Summary
static String MOOD_TEXT_PROPERTY
          Identifies the mood message property.
static String STATUS_PROPERTY
          Identifies the status property.
 
Method Summary
 void addPropertyChangeListener(PropertyChangeListener listener)
          Adds a PropertyChangeListener to this user.
 boolean canDoSkypeIn()
          Indicates whether the current user can do SkypeIn.
 boolean canDoSkypeOut()
          Indicates whether the current user can do SkypeOut.
 boolean canDoVoiceMail()
          Indicates whether the current user can do VoiceMail.
 Profile.CallForwardingRule[] getAllCallForwardingRules()
          Gets the all call forwarding rules of the current user.
 String[] getAllLauguages()
          Deprecated. 
 String[] getAllValidSMSNumbers()
          Return all the valid SMS numbers.
 BufferedImage getAvatar()
          Gets the avatar of the current user.
 Date getBirthDay()
          Gets the birth day of the current user.
 String getCity()
          Gets the city of the current user.
 String getCountry()
          Gets the country of the current user.
 String getCountryByISOCode()
          Gets the country of the current user by the ISO code.
 int getCredit()
          Gets the credit of the current user.
 String getCreditCurrencyUnit()
          Gets the credit currency unit of the current user.
 String getFullName()
          Gets the full name of the current user.
 String getHomePageAddress()
          Deprecated. 
 String getHomePhoneNumber()
          Gets the home phone number of the current user.
 String getId()
          Gets the Skype ID (username) of the current user.
 String getIntroduction()
          Gets the introduction of the current user.
 String getIPCountryByISOCode()
          Gets the IP country of the current user by the ISO code.
 String getLanguageByISOCode()
          Get the language by ISO code of the current user.
 String getMobilePhoneNumber()
          Gets the mobile phone number of the current user.
 String getMoodMessage()
          Gets the mood message of the current user.
 String getOfficePhoneNumber()
          Gets the office phone number of the current user.
 String getProvince()
          Gets the province of the current user.
 int getPSTNBalance()
          Deprecated. 
 String getPSTNBalanceCurrencyUnit()
          Deprecated. 
 String getRichMoodMessage()
          Gets the rich mood message of the current user.
 Profile.Sex getSex()
          Gets the sex of the current user.
 Profile.Status getStatus()
          Gets the online status of the current user.
 int getTimeZone()
          Gets the time zone of the current user.
 int getWaitTimeBeforeCallForwarding()
          Gets the wait time in seconds before starting a call forwarding.
 String getWebSiteAddress()
          Gets the web site address of the current user.
 boolean isCallForwarding()
          Indicates whether the call forwarding function is on.
 boolean isVideoCapable()
          Indicates whether the current user has a web camera.
 void removePropertyChangeListener(PropertyChangeListener listener)
          Removes the PropertyChangeListener from this user.
 void setAllCallForwardingRules(Profile.CallForwardingRule[] newValues)
          Sets the all call forwarding rules of the current user.
 void setAllLanguages(String[] newValues)
          Deprecated. 
 void setAvatar(BufferedImage newValue)
          Sets the avatar of the current user.
 void setAvatarByFile(File newValue)
          Sets the avatar of the current user by a file .
 void setBirthDay(Date newValue)
          Sets the birth day of the current user.
 void setCallForwarding(boolean on)
          Starts or stops the call forwarding function.
 void setCity(String newValue)
          Sets the city of the current user.
 void setCountry(String newValue)
          Sets the country of the current user.
 void setCountryByISOCode(String newValue)
          Sets the country of the current user by the ISO code.
 void setFullName(String newValue)
          Sets the full name of the current user.
 void setHomePageAddress(String newValue)
          Deprecated. 
 void setHomePhoneNumber(String newValue)
          Sets the home phone number of the current user.
 void setIntroduction(String newValue)
          Sets the introduction of the current user.
 void setLanguageByISOCode(String newValue)
          Sets the language by ISO code of the current user.
 void setMobilePhoneNumber(String newValue)
          Sets the mobile phone number of the current user.
 void setMoodMessage(String newValue)
          Sets the mood message of the current user.
 void setOfficePhoneNumber(String newValue)
          Sets the office phone number of the current user.
 void setProvince(String newValue)
          Sets the province of the current user.
 void setRichMoodMessage(String newValue)
          Sets the rich mood message of the current user.
 void setSex(Profile.Sex newValue)
          Sets the sex of the current user by the Profile.Sex enum.
 void setStatus(Profile.Status newValue)
          Sets the online status of the current user by the Profile.Status enum.
 void setTimeZone(int newValue)
          Sets the time zone of the current user.
 void setWaitTimeBeforeCallForwarding(int newValue)
          Sets the wait time in seconds before starting a call forwarding.
 void setWebSiteAddress(String newValue)
          Sets the web site address of the current user.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

STATUS_PROPERTY

public static final String STATUS_PROPERTY
Identifies the status property.

See Also:
Constant Field Values

MOOD_TEXT_PROPERTY

public static final String MOOD_TEXT_PROPERTY
Identifies the mood message property.

See Also:
Constant Field Values
Method Detail

getStatus

public Profile.Status getStatus()
                         throws SkypeException
Gets the online status of the current user.

Returns:
the online status of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setStatus(Status)

setStatus

public void setStatus(Profile.Status newValue)
               throws SkypeException
Sets the online status of the current user by the Profile.Status enum.

Parameters:
newValue - the new online status of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getStatus()

getId

public String getId()
             throws SkypeException
Gets the Skype ID (username) of the current user.

Returns:
the Skype ID (username) of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.

canDoSkypeOut

public boolean canDoSkypeOut()
                      throws SkypeException
Indicates whether the current user can do SkypeOut.

Returns:
true if the current user can do SkypeOut; false otherwise.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.

canDoSkypeIn

public boolean canDoSkypeIn()
                     throws SkypeException
Indicates whether the current user can do SkypeIn.

Returns:
true if the current user can do SkypeIn; false otherwise.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.

canDoVoiceMail

public boolean canDoVoiceMail()
                       throws SkypeException
Indicates whether the current user can do VoiceMail.

Returns:
true if the current user can do VoiceMail; false otherwise.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.

getPSTNBalance

@Deprecated
public int getPSTNBalance()
                   throws SkypeException
Deprecated. 

Gets the balance of the current user.

Returns:
the balance of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.

getCredit

public int getCredit()
              throws SkypeException
Gets the credit of the current user.

Returns:
the balance of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.

getPSTNBalanceCurrencyUnit

@Deprecated
public String getPSTNBalanceCurrencyUnit()
                                  throws SkypeException
Deprecated. 

Gets the currency code of the current user.

Returns:
the currency code of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.

getCreditCurrencyUnit

public String getCreditCurrencyUnit()
                             throws SkypeException
Gets the credit currency unit of the current user.

Returns:
the currency code of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.

getFullName

public String getFullName()
                   throws SkypeException
Gets the full name of the current user.

Returns:
the full name of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setFullName(String)

setFullName

public void setFullName(String newValue)
                 throws SkypeException
Sets the full name of the current user.

Parameters:
newValue - the new full name of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getFullName()

getBirthDay

public Date getBirthDay()
                 throws SkypeException
Gets the birth day of the current user.

Returns:
the birth day of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setBirthDay(Date)

setBirthDay

public void setBirthDay(Date newValue)
                 throws SkypeException
Sets the birth day of the current user.

Parameters:
newValue - the new birth day of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getBirthDay()

getSex

public Profile.Sex getSex()
                   throws SkypeException
Gets the sex of the current user.

Returns:
the sex of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setSex(Sex)

setSex

public void setSex(Profile.Sex newValue)
            throws SkypeException
Sets the sex of the current user by the Profile.Sex enum.

Parameters:
newValue - the new sex of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getSex()

getAllLauguages

@Deprecated
public String[] getAllLauguages()
                         throws SkypeException
Deprecated. 

Gets the all languages of the current user.

Returns:
the all languages of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setAllLanguages(String[])

getLanguageByISOCode

public String getLanguageByISOCode()
                            throws SkypeException
Get the language by ISO code of the current user.

Returns:
the language of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
#setLanguage(String)

setAllLanguages

@Deprecated
public void setAllLanguages(String[] newValues)
                     throws SkypeException
Deprecated. 

Sets the all languages of the current user.

Parameters:
newValues - the all new languages of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getAllLauguages()

setLanguageByISOCode

public void setLanguageByISOCode(String newValue)
                          throws SkypeException
Sets the language by ISO code of the current user.

Parameters:
newValues - the language by ISO code of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getAllLauguages()

getCountryByISOCode

public String getCountryByISOCode()
                           throws SkypeException
Gets the country of the current user by the ISO code.

Returns:
the country of the current user by the ISO code.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setCountryByISOCode(String), ISO 3166-1

getIPCountryByISOCode

public String getIPCountryByISOCode()
                             throws SkypeException
Gets the IP country of the current user by the ISO code.

Returns:
the country of the current user by the ISO code.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
ISO 3166-1

setCountryByISOCode

public void setCountryByISOCode(String newValue)
                         throws SkypeException
Sets the country of the current user by the ISO code.

Parameters:
newValue - the new country of the current user by the ISO code.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getCountryByISOCode(), ISO 3166-1

getCountry

public String getCountry()
                  throws SkypeException
Gets the country of the current user.

Returns:
the country of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setCountry(String)

setCountry

public void setCountry(String newValue)
                throws SkypeException
Sets the country of the current user.

Parameters:
newValue - the new country of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getCountry()

getProvince

public String getProvince()
                   throws SkypeException
Gets the province of the current user.

Returns:
the province of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setProvince(String)

setProvince

public void setProvince(String newValue)
                 throws SkypeException
Sets the province of the current user.

Parameters:
newValue - the new province of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getProvince()

getCity

public String getCity()
               throws SkypeException
Gets the city of the current user.

Returns:
the city of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setCity(String)

setCity

public void setCity(String newValue)
             throws SkypeException
Sets the city of the current user.

Parameters:
newValue - the new city of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getCity()

getHomePhoneNumber

public String getHomePhoneNumber()
                          throws SkypeException
Gets the home phone number of the current user.

Returns:
the home phone number of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setHomePhoneNumber(String)

setHomePhoneNumber

public void setHomePhoneNumber(String newValue)
                        throws SkypeException
Sets the home phone number of the current user.

Parameters:
newValue - the new home phone number of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getHomePhoneNumber()

getOfficePhoneNumber

public String getOfficePhoneNumber()
                            throws SkypeException
Gets the office phone number of the current user.

Returns:
the office phone number of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setOfficePhoneNumber(String)

setOfficePhoneNumber

public void setOfficePhoneNumber(String newValue)
                          throws SkypeException
Sets the office phone number of the current user.

Parameters:
newValue - the new office phone number of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getOfficePhoneNumber()

getMobilePhoneNumber

public String getMobilePhoneNumber()
                            throws SkypeException
Gets the mobile phone number of the current user.

Returns:
the mobile phone number of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setMobilePhoneNumber(String)

setMobilePhoneNumber

public void setMobilePhoneNumber(String newValue)
                          throws SkypeException
Sets the mobile phone number of the current user.

Parameters:
newValue - the new mobile phone number of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getMobilePhoneNumber()

getHomePageAddress

@Deprecated
public String getHomePageAddress()
                          throws SkypeException
Deprecated. 

Gets the home page address of the current user.

Returns:
the home page address of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setHomePageAddress(String)

getWebSiteAddress

public String getWebSiteAddress()
                         throws SkypeException
Gets the web site address of the current user.

Returns:
the web site address of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setWebSiteAddress(String)

setHomePageAddress

@Deprecated
public void setHomePageAddress(String newValue)
                        throws SkypeException
Deprecated. 

Sets the home page address of the current user.

Parameters:
newValue - the new home page address of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getHomePageAddress()

setWebSiteAddress

public void setWebSiteAddress(String newValue)
                       throws SkypeException
Sets the web site address of the current user.

Parameters:
newValue - the new web site address of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getWebSiteAddress()

getIntroduction

public String getIntroduction()
                       throws SkypeException
Gets the introduction of the current user.

Returns:
the introduction of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setIntroduction(String)

setIntroduction

public void setIntroduction(String newValue)
                     throws SkypeException
Sets the introduction of the current user.

Parameters:
newValue - the new introduction of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getIntroduction()

getMoodMessage

public String getMoodMessage()
                      throws SkypeException
Gets the mood message of the current user.

Returns:
the mood message of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setMoodMessage(String)

setMoodMessage

public void setMoodMessage(String newValue)
                    throws SkypeException
Sets the mood message of the current user.

Parameters:
newValue - the new mood message of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getMoodMessage()

getRichMoodMessage

public String getRichMoodMessage()
                          throws SkypeException
Gets the rich mood message of the current user.

Returns:
the rich mood message of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
Since:
Protocol 7
See Also:
setRichMoodMessage(String)

setRichMoodMessage

public void setRichMoodMessage(String newValue)
                        throws SkypeException
Sets the rich mood message of the current user.

Parameters:
newValue - the new rich mood message of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
Since:
Protocol 7
See Also:
getRichMoodMessage()

setAvatar

public void setAvatar(BufferedImage newValue)
               throws SkypeException
Sets the avatar of the current user.

Parameters:
newValue - the new image of the avatar.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
Since:
Protocol 7
See Also:
setAvatarByFile(File), getAvatar()

setAvatarByFile

public void setAvatarByFile(File newValue)
                     throws SkypeException
Sets the avatar of the current user by a file .

Parameters:
newValue - the new image file of the avatar.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
Since:
Protocol 7
See Also:
setAvatar(BufferedImage), getAvatar()

getAvatar

public BufferedImage getAvatar()
                        throws SkypeException
Gets the avatar of the current user.

Returns:
the avatar image of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
Since:
Protocol 7
See Also:
setAvatar(BufferedImage), setAvatarByFile(File)

getTimeZone

public int getTimeZone()
                throws SkypeException
Gets the time zone of the current user.

Returns:
the time zone of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setTimeZone(int)

setTimeZone

public void setTimeZone(int newValue)
                 throws SkypeException
Sets the time zone of the current user.

Parameters:
newValue - the new time zone of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getTimeZone()

isVideoCapable

public boolean isVideoCapable()
                       throws SkypeException
Indicates whether the current user has a web camera.

Returns:
true if the current user has a web camera; false otherwise.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.

getWaitTimeBeforeCallForwarding

public int getWaitTimeBeforeCallForwarding()
                                    throws SkypeException
Gets the wait time in seconds before starting a call forwarding.

Returns:
the wait time in seconds before starting a call forwarding.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setWaitTimeBeforeCallForwarding(int)

setWaitTimeBeforeCallForwarding

public void setWaitTimeBeforeCallForwarding(int newValue)
                                     throws SkypeException
Sets the wait time in seconds before starting a call forwarding.

Parameters:
newValue - the new wait time in seconds before starting a call forwarding.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getWaitTimeBeforeCallForwarding()

isCallForwarding

public boolean isCallForwarding()
                         throws SkypeException
Indicates whether the call forwarding function is on.

Returns:
true if the call forwarding function is on; false otherwise.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setCallForwarding(boolean)

setCallForwarding

public void setCallForwarding(boolean on)
                       throws SkypeException
Starts or stops the call forwarding function.

Parameters:
on - if true, starts the call forwarding function; otherwise, stops the call forwarding function
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
isCallForwarding()

getAllCallForwardingRules

public Profile.CallForwardingRule[] getAllCallForwardingRules()
                                                       throws SkypeException
Gets the all call forwarding rules of the current user.

Returns:
the all call forwarding rules of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
setAllCallForwardingRules(CallForwardingRule[])

setAllCallForwardingRules

public void setAllCallForwardingRules(Profile.CallForwardingRule[] newValues)
                               throws SkypeException
Sets the all call forwarding rules of the current user.

Parameters:
newValues - the new all call forwarding rules of the current user.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.
See Also:
getAllCallForwardingRules()

getAllValidSMSNumbers

public String[] getAllValidSMSNumbers()
                               throws SkypeException
Return all the valid SMS numbers.

Returns:
Array of Strings with the numbers.
Throws:
SkypeException - when the connection has gone bad or an ERROR message is received.

addPropertyChangeListener

public final void addPropertyChangeListener(PropertyChangeListener listener)
                                     throws SkypeException
Adds a PropertyChangeListener to this user.

The listener is registered for all bound properties of this user, including the following:

If listener is null, no exception is thrown and no action is performed.

Parameters:
listener - the PropertyChangeListener to be added
Throws:
SkypeException
See Also:
removePropertyChangeListener(PropertyChangeListener)

removePropertyChangeListener

public final void removePropertyChangeListener(PropertyChangeListener listener)
Removes the PropertyChangeListener from this user.

If listener is null, no exception is thrown and no action is performed.

Parameters:
listener - the PropertyChangeListener to be removed
See Also:
addPropertyChangeListener(PropertyChangeListener)


Copyright © 2004-2011. All Rights Reserved.