Skip to content

Instantly share code, notes, and snippets.

@csainty
Created July 5, 2011 03:56
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save csainty/1064230 to your computer and use it in GitHub Desktop.
Save csainty/1064230 to your computer and use it in GitHub Desktop.
Draft Inmate model for Macto
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Macto
{
public class Inmate
{
public int Id { get; set; }
public string Name { get; set; }
public DateTime DateOfBirth { get; set; }
public int RegularLocationId { get; set; } // Cell Block Identifier
public int CurrentLocationId { get; set; } // Hospital / Court etc Identifier
public string ImageLocation { get; set; } // RavenDb Attachment
public ICollection<Warrant> Warrants { get; set; }
}
public class Warrant
{
public WarrantType WarrantType { get; set; }
public IssuingAuthority IssuingAuthority { get; set; }
public string Issuer { get; set; }
public DateTime IssueDate { get; set; }
public DateTime EffectiveDate { get; set; }
public DateTime ExpiryDate { get; set; } // Store along with duration for ease of querying
public TimeSpan Duration { get; set; } // Store along with expiry date for ease of review
public string DocumentLocation { get; set; } // RavenDb Attachment?
}
public enum WarrantType
{
Arrest,
Detention,
Remand,
Sentencing
}
public enum IssuingAuthority
{
Officer,
Court
}
}
@devnetfx
Copy link

devnetfx commented Jul 6, 2011

I think, Inmate needs the following fields as well

public string Name { get; set; }
public DateTime DateOfBirth { get; set; }

Also, Sentencing (spelling) in Warrant type

@csainty
Copy link
Author

csainty commented Jul 6, 2011

Updated. Lol @ missing the name field. DateOfBirth might need to be nullable as an inmate dropped on the doorstep may refuse identification for a time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment