• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
Keine Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

Commit MetaInfo

Revisione14cdd7e045c10524eb1c004c19494754a47e2e4 (tree)
Zeit2022-06-05 00:39:06
Autoryoshy <yoshy.org.bitbucket@gz.j...>
Commiteryoshy

Log Message

[MOD] UseCaseResponse のエラー取得系メソッドをプロパティ化

Ändern Zusammenfassung

Diff

--- a/Adaptor/Controller/Handler/AbstractErrorHandler.cs
+++ b/Adaptor/Controller/Handler/AbstractErrorHandler.cs
@@ -23,12 +23,12 @@ namespace CleanAuLait.Adaptor.Controller.Handler
2323
2424 //string statusText = !String.IsNullOrEmpty(res.Message) ? res.Message : AppConst.STATUS_BAR_READY;
2525
26- if (res.HasSomeErrors())
26+ if (res.HasSomeErrors)
2727 {
2828 //dialog.ShowError(res.Message, req.UIInfo);
2929 dialog.ShowError(res.Message);
3030 }
31- else if (res.IsAborted())
31+ else if (res.IsAborted)
3232 {
3333 //dialog.ShowInfo(res.Message, req.UIInfo);
3434 dialog.ShowInfo(res.Message);
--- a/UseCase/Response/UseCaseResponse.cs
+++ b/UseCase/Response/UseCaseResponse.cs
@@ -48,20 +48,11 @@
4848 };
4949 }
5050
51- public bool IsSuccess()
52- {
53- return (Result & UseCaseResultTypes.ABORTED) == 0;
54- }
51+ public bool IsSuccess => (Result & UseCaseResultTypes.ABORTED) == 0;
5552
56- public bool IsAborted()
57- {
58- return (Result & UseCaseResultTypes.ABORTED) != 0;
59- }
53+ public bool IsAborted => (Result & UseCaseResultTypes.ABORTED) != 0;
6054
61- public bool HasSomeErrors()
62- {
63- return (Result & UseCaseResultTypes.SOME_ERRORS_IGNORED) != 0;
64- }
55+ public bool HasSomeErrors => (Result & UseCaseResultTypes.SOME_ERRORS_IGNORED) != 0;
6556
6657 }
6758 }