Class From

  • All Implemented Interfaces:
    Serializable

    public class From
    extends NamedFacebookType
    From type is used as replacement for the case we need a user or a page. Because these both types have different fields we have this special handling. Because the minimal intersection of page and user are id and name, so the From object extends the {@see NamedFacebookType} and as fast access name and id are available.
    See Also:
    Serialized Form
    • Constructor Detail

      • From

        public From()
    • Method Detail

      • getAsUser

        public User getAsUser()
        returns the from field as {@see com.restfb.types.User} object
        Returns:
        the from field as User
      • getAsPage

        public Page getAsPage()
        returns the from field as {@see com.restfb.types.Page} object
        Returns:
        the from field as Page