Skip to content
This repository has been archived by the owner on Aug 3, 2019. It is now read-only.

Get television

Roman Kushnarenko edited this page Oct 29, 2014 · 2 revisions

Initialize callback listener:

OnPagesListener onPagesListener = new OnPagesListener() {			
	@Override
	public void onComplete(List<Page> television) {
		Log.i(TAG, "Number of television = " + television.size());
	}

	/* 
	 * You can override other methods here: 
	 * onThinking(), onFail(String reason), onException(Throwable throwable)
	 */		
};

Get television series:

mSimpleFacebook.getTelevision(onPagesListener);

Be specific and get what you need

By using this option, you define the properties you need, and you will get only them. Here, any property is possible to get.

Prepare the properties that you need:

Page.Properties properties = new Page.Properties.Builder()
	.add(Properties.ID)
	.add(Properties.NAME)
	.add(Properties.LINK)
	.build();

Get television:

mSimpleFacebook.getTelevision(properties, onPagesListener);

Get television of other users

If user's television privacy is defined to public, then, you can access these television, or if person is using your app and also accepted the same permissions:

Get television:

mSimpleFacebook.getTelevision(profileId, onPagesListener);

Same for properties:

mSimpleFacebook.getTelevision(profileId, properties, onPagesListener);
Clone this wiki locally