nn::friends::CTR::GetFriendAttributeFlags Function

Syntax

Result GetFriendAttributeFlags(
     bit32 * pAttributeFlagsList,
     const PrincipalId * pPrincipalIdList,
     size_t size = 1
);

Parameters

Name Description
out pAttributeFlagsList Specifies a pointer to the buffer that stores obtained relationship information.
in pPrincipalIdList Specifies a pointer to a list of principal IDs.
in size Specifies the number of buffer elements in the principal ID list.

Return Values

Returns the result of the operation.

Value Description
Result::IsSuccess Process succeeded.
ResultInvalidPointer Invalid pointer passed as argument.
ResultTooLarge The value passed as the argument is too large.
ResultNotInitialized The friend presence library is not initialized.
Other Another result may be returned, depending on the internal state of the daemon and other factors.

Description

Gets a list of friend relationships.

Friend relationships are represented as a bitwise OR of attributes. Friends that have established a friend relationship with the local host at least once have the nn::friends::CTR::ATTRIBUTE_FLAG_ESTABLISHED bit set to 1. Friends who meet all of the following conditions have the nn::friends::CTR::ATTRIBUTE_REMOTE_ACCESSIBLE bit set to 1.
・ A friend relationship has been established on the friend server (this does not include the local friend state)
・ The friend has not deleted the friend relationship, or if they have, that fact has not been synchronized yet from the friend server

The friend list on the local system does not explicitly show the user that the friend has deleted their friend relationship, and it appears to the user as if that person is always offline. We consider the fact that the behavior is the same to the fullest extent so that developers do not need to worry about it when using the friend presence library or the NEX library. When accessing the latest data about users in friend lists on independent servers, use the nn::friends::CTR::ATTRIBUTE_REMOTE_ACCESSIBLE bit to determine if the latest friend relationships can be evaluated only locally and it is difficult to hide the deletion of friend relationships.

Revision History

2012/02/16
Added an explanation about the ATTRIBUTE_FLAG_REMOTE_ACCESSIBLE bit.
2011/03/11
Noted that the function will still return success even if an invalid local friend code returned.
Added specific examples of return values.
2010/08/16
Initial version.

CONFIDENTIAL