public class FacebookShare

  1. Object
  2. Command
  3. ShareService
  4. FacebookShare

ImplementsActionListener<ActionEvent>

Deprecated. This share service relies on the legacy FaceBookAccess OAuth/Graph flow which is no longer supported by Facebook. Use a BrowserComponent pointed at a Facebook share URL, or delegate to the native share sheet. This class will be removed in a future release.
Facebook sharing service

Constructors

public FacebookShare()Default Constructor

Methods

public Image getIcon()Returns the icon representing the command
public boolean equals(Object o)compare two commands
public int hashCode()Allows storing commands in a vector/hashtable
public void actionPerformed(ActionEvent evt)This method is called when the soft button/Menu item is clicked
public void share(String text, String image, String mime)This is the image sharing method which should be implemented by the service, if the service returned true on the canShareImage() method Notice not all services are able to share text and image together, in this case the image sharing will b…
public void share(String toShare)This is the sharing method which should be implemented by the service.
public boolean canShareImage()The implementing service needs to declare if it is capable to share an image

Inherited fields

Inherited methods

Constructor details

FacebookShare

public FacebookShare()
Default Constructor

Method details

getIcon

public Image getIcon()
Returns the icon representing the command

Returns

an icon representing the command

equals

public boolean equals(Object o)
compare two commands

Parameters

o Object
a Command Object to compare

Returns

true if the obj has the same command name

hashCode

public int hashCode()
Allows storing commands in a vector/hashtable

Returns

unique hashcode for the command class

actionPerformed

public void actionPerformed(ActionEvent evt)
This method is called when the soft button/Menu item is clicked

Parameters

evt ActionEvent
the Event Object

share

public void share(String text, String image, String mime)
This is the image sharing method which should be implemented by the service, if the service returned true on the canShareImage() method Notice not all services are able to share text and image together, in this case the image sharing will be preferred by these services

Parameters

text String
text to share
image String
image to share
mime String
Not documented.

share

public void share(String toShare)
This is the sharing method which should be implemented by the service.

Parameters

toShare String
text to share

canShareImage

public boolean canShareImage()
The implementing service needs to declare if it is capable to share an image

Returns

true if the service can share images