{"action":"opened","issue":{"url":"https://api.github.com/repos/SafeSlingerProject/exchange-python-web/issues/1","labels_url":"https://api.github.com/repos/SafeSlingerProject/exchange-python-web/issues/1/labels{/name}","comments_url":"https://api.github.com/repos/SafeSlingerProject/exchange-python-web/issues/1/comments","events_url":"https://api.github.com/repos/SafeSlingerProject/exchange-python-web/issues/1/events","html_url":"https://github.com/SafeSlingerProject/exchange-python-web/issues/1","id":53670696,"number":1,"title":"new structure model for removing UI level","user":{"login":"mwfarb","id":215994,"avatar_url":"https://avatars.githubusercontent.com/u/215994?v=3","gravatar_id":"","url":"https://api.github.com/users/mwfarb","html_url":"https://github.com/mwfarb","followers_url":"https://api.github.com/users/mwfarb/followers","following_url":"https://api.github.com/users/mwfarb/following{/other_user}","gists_url":"https://api.github.com/users/mwfarb/gists{/gist_id}","starred_url":"https://api.github.com/users/mwfarb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mwfarb/subscriptions","organizations_url":"https://api.github.com/users/mwfarb/orgs","repos_url":"https://api.github.com/users/mwfarb/repos","events_url":"https://api.github.com/users/mwfarb/events{/privacy}","received_events_url":"https://api.github.com/users/mwfarb/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/SafeSlingerProject/exchange-python-web/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-01-07T19:24:06Z","updated_at":"2015-01-07T19:24:06Z","closed_at":null,"body":"So here is a away we might construct the python and javascript to allow any developer to implement the UI they feel is appropriate (SafeSlingerProject/exchange-javascript/issues/1).\r\n\r\nConsider the 3rd-party developer building their app, in our case it is a demo app. Our demo app has a Main object and 2 objects to stage in sequence: SafeSlinger (all protocol and web code) and UI (all UI code). So that the SafeSlinger object can be the only public object, and the implementer can define anything they want for the UI object. The Main object, might be HTML or javascript or python. In psuedocode it might look like the following.\r\n\r\n```\r\nclass Main {\r\n  UI ui = new UI();\r\n  SafeSlinger ss = new SafeSlinger();\r\n  \r\n  // this is our demo starting to show start-up fields to run it\r\n  ui.showDemoView_GetServerAndSecret();\r\n\r\n  ss.doSetup( ui.server, ui.secret );\r\n  ui.showNumUsersView_GetNumUsers();\r\n  ss.doAssignUser( ui.numUsers );\r\n  ui.showGroupingView_GetGroupNum( ss.numUsers );\r\n  ss.doSyncCommitsAndData( ui.groupingNum );\r\n  ui.showVerifyView_GetMatchDecision( ss.numUsers, ss.CorrectPhrase, ss.DecoyPhrase1, ss.DecoyPhrase2 );\r\n  ss.doFinalVerification( ss.doesPhraseMatchAll );\r\n\r\n  // now the implementer could call something like\r\n  byte[][] decryptedData = ss.getDecryptedData();\r\n\r\n  // and then in our demo example, show results\r\n  ui.showExcahngedSecrets( decryptedData );\r\n}\r\n```"}}