Skip to main content

The Project: Entity Modeling

I've said it before, I kinda know what this program needs to do. Translating that into C# objects that will interact with each other intelligently and efficiently...that's a whole 'nother can of worms that I personally find easier as a visual.


A series of class diagrams representing database entities

I know Students will have courses. Courses will have evaluations (like quizzes and tests). Evaluations will have Scores. Deciding how that works, from a database perspective, will help ensure I'm configuring my code to back into the correct place and identify ways to simplify the data layer--storing instructors in their own table will allow possible features down the road of letting students see how many A's a teacher hands out historically, for instance, but also makes me decide if my entity should have an instructor object attached, or should that be a domain model thing?

I'm a very goal-oriented person in that if I know there's a river to cross 500 miles from now, I want to plan the next 500 miles of route to put me exactly where I want to cross that river. Maybe you're more of the school of thought to get to the river ASAP and then figure out how to cross. Both approaches will get one across the river, but I prefer to have a plan that takes known obstacles into account (that I can modify as needed) than to make it up on the fly as things come up.

Comments

Popular posts from this blog

Use Cases: The Theory

They told me in my CSCI-1275 Systems Analysis and Design course there's a tendency for programmers to just start coding stuff without thinking, and this was nigh on tantamount to total catastrophe. I didn't fully understand this until a little later in the semester. We had just learned about arrays and collections in my CSCI-1630 C# Programming I course, and I found this to be a perfect excuse to write a little application that would synthetically divide polynomials . (That's a really great way to master synthetic division, actually, if you're interested in brushing up on that skill. Although my wife still insists the time would have been better spent putting more time into my algebra homework. Two types of people...). At any rate, long story short: I made the program work perfectly, for 3rd degree polynomials that divided evenly. Then I realized it broke when I tried a polynomial of the 4th degree. And then again when the 3rd degree polynomial had a remainder. ...

Sequence Diagrams: Theorizing

The activity diagram is all well and good, and can even be super useful in a lot of cases. But for my money, so far in my limited experience, the sequence diagram is where you really start to get a handle on what you need to do as a programmer. Before the sequence diagram, you're dealing with steps in a process. What needs to happen, in what order, and you could just as easily be talking about employees or way stations or widgets or nothing at all. They're really about systems analysis--that high level, what needs to happen kind of stuff. Really important work, but totally dull from a programmer standpoint. The sequence diagram is where we start seeing method names and parameters being laid out. The interaction between classes and layers. You start to see what methods you'll need, in what classes, and get a feel for what properties those classes will need. You can see the flow of the data from the start of the operation to the end, note the inputs and the outputs. I...

Activity Diagram: Theory

So I've got use cases figured out. Not all of them--only a fool or a genius thinks he can sit at a desk away from the end user and think he's got all the use cases figured out (and a genius would never truly believe it). But you can't sit around trying to anticipate every possible use case before you start, so once we have enough to cobble together a complete program or part of one we can move on for a bit. Side note, this is the beauty of the agile approach: "Yeah, we know we gotta go to the moon. But we have to do it in 10 years, so we can't spend 5 years thinking up every problem we might need to solve before we start solving them. How about we start with 'design a rocket that reaches orbit without killing anyone' and build on that when we finish?" That's called an iteration, but more on that later. Fleshing out what that use case needs is the next step, and there are a couple tools I remember being taught. One of them is the activity diagra...