I have created the content provider class below.
Now the content provider has to be registered in the manifest.
Professor Code Girl
Thursday, July 3, 2014
Project Database - Step 4
Below is an entity relationship diagram with the ProjectItem table created by Gliffy.
![]() |
ERD Diagram with data types |
I've decided to do all of my dates in UTC format and store them as text, as discussed in stack overflow post. I've decided to have a field in case I store an icon for each task later.
One of the more unique things I'm introducing into this app is the ParentProjectItem. Because larger tasks can generally infinitely be broken up into sub tasks, I want to form a ProjectItem heiarchy. ProjectItems that have a ProjectItemParentID of 0 are root level ProjectItems, sub ProjectItems will have the idea of their parent stored in this field. I have tried to edit the ERD diagram to reflect this.
![]() |
Tried to add the one-to-one relationship, this will get very interesting in the iOS storyboarding! |
Now it is time to create the Java class that has the code that will create this table. I will upload it to my newly created GitHub repository and you can see the class ProjectItemTable.java below.
The class above creates or performs updates on the ProjectItem table in the database. It is good practice to have one class to each table, as I add tables I will update my diagrams and add classes to my code.
Stack Overflow
I had to join StackOverflow, it's about time I build some reputation on that site and become a contributor rather than just a spectator! Find me here.
Udacity Android Course
I was contacted by someone and given a link to about the coolest Android course I've seen yet, I will be looking into it further. This course can be found at udacity and the free courseware is certainly enough to entertain me for a few hours.
Git Repository
I have been dreading this moment but maybe I will just tackle this now. How am I going to share source code?
Well, I think I am going to use Git. The information about Git is online. I am using Eclipse and when I did a search I saw another vogella tutorial. I liked the last one so let's do that. This tutorial is about EGit, an Eclipse plugin, that I first must install.
EGit Vogella Tutorial
So first I need my Eclipse in line so I go to help, install software, hit the add button and put in the update site.
Great, now I will just install everything.
That was a huge pain in the backside! But I figured it out! Here is my github.com repository that I pushed from Eclipse using the above plugins.
Well, I think I am going to use Git. The information about Git is online. I am using Eclipse and when I did a search I saw another vogella tutorial. I liked the last one so let's do that. This tutorial is about EGit, an Eclipse plugin, that I first must install.
EGit Vogella Tutorial
So first I need my Eclipse in line so I go to help, install software, hit the add button and put in the update site.
![]() |
Adding an Eclipse Plugin |
That was a huge pain in the backside! But I figured it out! Here is my github.com repository that I pushed from Eclipse using the above plugins.
I also discovered a nice tool called 'GIST' which allows me to embed code excerpts. Or I can create a link like this Link to My Code.
Now I can publish my samples and have version control!
This user guide was the most helpful thing in setting up EGit with Eclipse.
This user guide was the most helpful thing in setting up EGit with Eclipse.
Subscribe to:
Posts (Atom)