added Async suffix to public async methods

This commit is contained in:
Austin Diviness 2015-08-11 06:36:15 -07:00
Родитель b53532fb0e
Коммит 6ef649a67a
11 изменённых файлов: 38 добавлений и 38 удалений

Просмотреть файл

@ -39,7 +39,7 @@ FBSingleValue::FBSingleValue(
{
}
Windows::Foundation::IAsyncOperation<FBResult^>^ FBSingleValue::Get(
Windows::Foundation::IAsyncOperation<FBResult^>^ FBSingleValue::GetAsync(
)
{
return create_async([this]() -> task<FBResult^>
@ -54,7 +54,7 @@ Windows::Foundation::IAsyncOperation<FBResult^>^ FBSingleValue::Get(
});
}
Windows::Foundation::IAsyncOperation<FBResult^>^ FBSingleValue::Post(
Windows::Foundation::IAsyncOperation<FBResult^>^ FBSingleValue::PostAsync(
)
{
return create_async([this]() -> task<FBResult^>
@ -69,7 +69,7 @@ Windows::Foundation::IAsyncOperation<FBResult^>^ FBSingleValue::Post(
});
}
Windows::Foundation::IAsyncOperation<FBResult^>^ FBSingleValue::Delete(
Windows::Foundation::IAsyncOperation<FBResult^>^ FBSingleValue::DeleteAsync(
)
{
return create_async([this]() -> task<FBResult^>

Просмотреть файл

@ -33,13 +33,13 @@ namespace Facebook
FBJsonClassFactory^ ObjectFactory
);
Windows::Foundation::IAsyncOperation<FBResult^>^ Get(
Windows::Foundation::IAsyncOperation<FBResult^>^ GetAsync(
);
Windows::Foundation::IAsyncOperation<FBResult^>^ Post(
Windows::Foundation::IAsyncOperation<FBResult^>^ PostAsync(
);
Windows::Foundation::IAsyncOperation<FBResult^>^ Delete(
Windows::Foundation::IAsyncOperation<FBResult^>^ DeleteAsync(
);
private:

Просмотреть файл

@ -43,7 +43,7 @@ FBPaginatedArray::FBPaginatedArray(
{
}
Windows::Foundation::IAsyncOperation<FBResult^>^ FBPaginatedArray::First(
Windows::Foundation::IAsyncOperation<FBResult^>^ FBPaginatedArray::FirstAsync(
)
{
return create_async([this]() -> task<FBResult^>
@ -56,7 +56,7 @@ Windows::Foundation::IAsyncOperation<FBResult^>^ FBPaginatedArray::First(
});
}
Windows::Foundation::IAsyncOperation<FBResult^>^ FBPaginatedArray::Next(
Windows::Foundation::IAsyncOperation<FBResult^>^ FBPaginatedArray::NextAsync(
)
{
return create_async([this]() -> task < FBResult^ >
@ -107,7 +107,7 @@ Windows::Foundation::IAsyncOperation<FBResult^>^ FBPaginatedArray::Next(
});
}
Windows::Foundation::IAsyncOperation<FBResult^>^ FBPaginatedArray::Previous(
Windows::Foundation::IAsyncOperation<FBResult^>^ FBPaginatedArray::PreviousAsync(
)
{
return create_async([this]() -> task < FBResult^ >

Просмотреть файл

@ -34,13 +34,13 @@ namespace Facebook
Facebook::FBJsonClassFactory^ ObjectFactory
);
Windows::Foundation::IAsyncOperation<FBResult^>^ First(
Windows::Foundation::IAsyncOperation<FBResult^>^ FirstAsync(
);
Windows::Foundation::IAsyncOperation<FBResult^>^ Next(
Windows::Foundation::IAsyncOperation<FBResult^>^ NextAsync(
);
Windows::Foundation::IAsyncOperation<FBResult^>^ Previous(
Windows::Foundation::IAsyncOperation<FBResult^>^ PreviousAsync(
);
property Windows::Foundation::Collections::IVectorView<Object^>^

Просмотреть файл

@ -207,7 +207,7 @@ ProfilePictureControl::GetProfilePictureInfo(
return FBProfilePicture::FromJson(JsonText);
}));
result = create_task(value->Get());
result = create_task(value->GetAsync());
}
return result;

Просмотреть файл

@ -162,7 +162,7 @@ void FBSession::ResetPermissions(
}
}
IAsyncAction^ FBSession::Logout()
IAsyncAction^ FBSession::LogoutAsync()
{
_permissions->Clear();
_user = nullptr;
@ -187,7 +187,7 @@ task<FBResult^> FBSession::GetUserInfo(
return FBUser::FromJson(JsonText);
}));
return create_task(value->Get());
return create_task(value->GetAsync());
}
String^ FBSession::PermissionsToString()
@ -421,7 +421,7 @@ IAsyncAction^ FBSession::TryDeleteTokenData(
});
}
Windows::Foundation::IAsyncOperation<FBResult^>^ FBSession::ShowFeedDialog(
Windows::Foundation::IAsyncOperation<FBResult^>^ FBSession::ShowFeedDialogAsync(
PropertySet^ Parameters
)
{
@ -478,7 +478,7 @@ Windows::Foundation::IAsyncOperation<FBResult^>^ FBSession::ShowFeedDialog(
return task;
}
Windows::Foundation::IAsyncOperation<FBResult^>^ FBSession::ShowRequestsDialog(
Windows::Foundation::IAsyncOperation<FBResult^>^ FBSession::ShowRequestsDialogAsync(
Windows::Foundation::Collections::PropertySet^ Parameters
)
{
@ -608,7 +608,7 @@ task<FBResult^> FBSession::GetAppPermissions(
return FBPermission::FromJson(JsonText);
}));
return create_task(permArr->First())
return create_task(permArr->FirstAsync())
.then([this, permArr](FBResult^ result)
{
if (result->Succeeded)

Просмотреть файл

@ -107,7 +107,7 @@ namespace Facebook
}
//! Clear all login information, e.g. user info, token string, etc.
Windows::Foundation::IAsyncAction^ Logout();
Windows::Foundation::IAsyncAction^ LogoutAsync();
//! User info - valid after successful login
property Facebook::Graph::FBUser^ User
@ -116,12 +116,12 @@ namespace Facebook
}
//! Launch 'feed' dialog, to post to user's timeline
Windows::Foundation::IAsyncOperation<FBResult^>^ ShowFeedDialog(
Windows::Foundation::IAsyncOperation<FBResult^>^ ShowFeedDialogAsync(
Windows::Foundation::Collections::PropertySet^ Parameters
);
//! Launch 'request' dialog, to send app
Windows::Foundation::IAsyncOperation<FBResult^>^ ShowRequestsDialog(
Windows::Foundation::IAsyncOperation<FBResult^>^ ShowRequestsDialogAsync(
Windows::Foundation::Collections::PropertySet^ Parameters
);

Просмотреть файл

@ -268,7 +268,7 @@ namespace FBWinStoreCsTests
return obj;
}));
FBResult fbresult = await sval.Get();
FBResult fbresult = await sval.GetAsync();
if (fbresult.Succeeded)
{
@ -303,7 +303,7 @@ namespace FBWinStoreCsTests
FBSingleValue sval = new FBSingleValue(path, Parameters,
new FBJsonClassFactory(FBTestUser.FromJson));
FBResult fbresult = await sval.Post();
FBResult fbresult = await sval.PostAsync();
if ((fbresult.Succeeded == false) || (fbresult.Object == null))
{
@ -344,7 +344,7 @@ namespace FBWinStoreCsTests
FBSingleValue sval = new FBSingleValue(path, parameters,
new FBJsonClassFactory(FBObject.FromJson));
FBResult fbresult = await sval.Post();
FBResult fbresult = await sval.PostAsync();
return (FBObject)fbresult.Object;
}
@ -361,7 +361,7 @@ namespace FBWinStoreCsTests
FBPaginatedArray arr = new FBPaginatedArray(path, parameters,
new FBJsonClassFactory(FBTestUser.FromJson));
FBResult result = await arr.First();
FBResult result = await arr.FirstAsync();
//Assert.IsTrue(result.Succeeded);
IReadOnlyList<Object> users = null;
@ -392,7 +392,7 @@ namespace FBWinStoreCsTests
FBSingleValue sval = new FBSingleValue(path, parameters,
new FBJsonClassFactory(FBSuccess.FromJson));
return await sval.Delete();
return await sval.DeleteAsync();
}
public async Task deleteTestUsers()
@ -454,7 +454,7 @@ namespace FBWinStoreCsTests
FBSingleValue sval = new FBSingleValue(path, parameters,
new FBJsonClassFactory(FBObject.FromJson));
return await sval.Post();
return await sval.PostAsync();
}
public async Task<FBResult> publishCustomStory(
@ -471,7 +471,7 @@ namespace FBWinStoreCsTests
FBSingleValue sval = new FBSingleValue(path, parameters,
new FBJsonClassFactory(FBObject.FromJson));
return await sval.Post();
return await sval.PostAsync();
}
[TestMethod]
@ -520,7 +520,7 @@ namespace FBWinStoreCsTests
FBPaginatedArray arr = new FBPaginatedArray(path, parameters,
new FBJsonClassFactory(FBTestUser.FromJson));
FBResult result = await arr.First();
FBResult result = await arr.FirstAsync();
Assert.IsTrue(result.Succeeded);
IReadOnlyList<Object> users =
@ -588,7 +588,7 @@ namespace FBWinStoreCsTests
FBSingleValue sval = new FBSingleValue(path, parameters,
new FBJsonClassFactory(FBPhoto.FromJson));
FBResult result = await sval.Post();
FBResult result = await sval.PostAsync();
Assert.IsTrue(result.Succeeded);
try
@ -625,7 +625,7 @@ namespace FBWinStoreCsTests
FBSingleValue sval = new FBSingleValue(path, parameters,
new FBJsonClassFactory(FBObject.FromJson));
FBResult result = await sval.Post();
FBResult result = await sval.PostAsync();
Assert.IsTrue(result.Succeeded);
try

Просмотреть файл

@ -63,7 +63,7 @@ IAsyncOperation<AppToken^>^ AppToken::Create(
return create_async([=]() -> task<AppToken^>
{
return create_task(sval->Get())
return create_task(sval->GetAsync())
.then([=](FBResult^ result) -> AppToken^
{
AppToken^ token = nullptr;

Просмотреть файл

@ -103,7 +103,7 @@ task<FBResult^> TestContext::CreateTestUser(
return TestUser::FromJson(JsonText);
}));
return create_task(val->Post());
return create_task(val->PostAsync());
}
task<FBResult^> TestContext::DeleteTestUser(
@ -126,7 +126,7 @@ task<FBResult^> TestContext::DeleteTestUser(
return APIResult::FromJson(JsonText);
}));
return create_task(val->Delete());
return create_task(val->DeleteAsync());
}
task<bool> TestContext::PopulateTestUsersCollection(
@ -145,7 +145,7 @@ task<bool> TestContext::PopulateTestUsersCollection(
if (_pagedResult->HasNext)
{
return create_task(_pagedResult->Next()).then([this](FBResult^ result) -> task<bool>
return create_task(_pagedResult->NextAsync()).then([this](FBResult^ result) -> task<bool>
{
if (result->Succeeded)
{
@ -197,7 +197,7 @@ task<bool> TestContext::GetTestUsers(
});
_pagedResult = ref new FBPaginatedArray(graphPath, parameters, fact);
return create_task(_pagedResult->First());
return create_task(_pagedResult->FirstAsync());
})
.then([this](FBResult^ result)
{

Просмотреть файл

@ -231,7 +231,7 @@ IAsyncOperation<FBResult^>^ TestRunner::UploadPhotoFromStream(
FBSingleValue^ sval = ref new FBSingleValue(Path, Parameters,
ref new FBJsonClassFactory(TestPhoto::FromJson));
return sval->Post();
return sval->PostAsync();
}
else
{
@ -256,7 +256,7 @@ IAsyncOperation<FBResult^>^ TestRunner::GetExtendedPhotoInfoFor(
FBSingleValue^ sval = ref new FBSingleValue(path, Parameters,
ref new FBJsonClassFactory(TestPhoto::FromJson));
op = sval->Get();
op = sval->GetAsync();
}
return op;