-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Source class #62
Source class #62
Conversation
Co-authored-by: Tim Hellhake <tim-hellhake@users.noreply.github.com>
…o WebThingsIO-main
How to revert complete files with git (for example
|
app/src/main/java/io/webthings/app/templates/ThingsTemplates.kt
Outdated
Show resolved
Hide resolved
@@ -1,7 +1,7 @@ | |||
#!/usr/bin/env sh | |||
#!/bin/sh |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please open a separate PR for updating the Gradle wrapper.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gradle was updated in the previous PR
<?xml version="1.0" encoding="utf-8"?> | ||
<resources> | ||
<style name="Theme.Webthings" parent="android:Theme.Material.Light.NoActionBar"> | ||
<item name="android:statusBarColor">@color/purple_700</item> | ||
</style> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please revert this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i didn'T edit this file yet?
Co-authored-by: Tim Hellhake <tim-hellhake@users.noreply.github.com>
Co-authored-by: Tim Hellhake <tim-hellhake@users.noreply.github.com>
Co-authored-by: Tim Hellhake <tim-hellhake@users.noreply.github.com>
Co-authored-by: Tim Hellhake <tim-hellhake@users.noreply.github.com>
Co-authored-by: Tim Hellhake <tim-hellhake@users.noreply.github.com>
Co-authored-by: Tim Hellhake <tim-hellhake@users.noreply.github.com>
my working way is not optimal yet, i'll delete this branch and PR and did a new cleaner one! |
Hi @arist0v, before you spend any more time on this I wanted to comment that I don't really agree with a I think the base class for the data model of devices should be
Given the Android App is implementing an existing API specification, the implementation will be a lot simpler if we stick to the existing data model rather than inventing a new one. I don't expect there to be other sources of devices other than a For WebThings Gateway 1.x, the gateway's own data model is a useful guide, though not perfect. I'm currently working on something very similar for WebThings Cloud and it would be great to keep the data model aligned with the standard across the whole platform. |
BTW, another source of inspiration when modelling the internal API for a consumed |
@benfrancis no problem, i'll work that way directly creating the correct class. But the source class will still be needed since it represent the gateway itself( is the gateway available, oauth2 login function, things discovery) so except if it have something i didn't properly understand, i'll still need a source for the things Also did we still allow adding multiple gateway to the same app? if yes it'S another important point for the source since it could have multiple source(multiple gateway) |
Basically:
In the WoT Discovery ontology, a Just to make things a bit more confusing, the In pseudo code...
To add an individual device to the app you would add a Is that making any sense? I'm in the process of figuring all this out for WebThings Cloud too, so we can figure it out together :) |
So if i get it right: 1 so i add a thing directory, if i have multiple gateway, i had multiple ThingDirectory so: ThingDirectory(url="myname.wetbhings.io", username="bob@gratton.org", password="Toothpaste") is it something like that? |
@arist0v Yes, exactly. |
ok so the next step in my process will be to create the ThingsDirectory class and then create a screen to add the settings (url username etc...) |
See #13. |
created basic source abstract class