public HttpResponseMessage AddVolunteer( [FromBody]Volunteer volunteer )
        {
            var rId = bal.GetRequestId();

            try
            {
                if ( ModelState.IsValid == false )
                {
                    bal.CreateRequestLogEntry( rId, "Expectation Failed", Request.RequestUri.PathAndQuery, Request.Method.Method, this.GetClientIp( Request ) );
                    return Request.CreateErrorResponse( HttpStatusCode.ExpectationFailed, new HttpError( "Information provided is incorrect." ) );
                }

                HttpResponseMessage response;
                var data = bal.CreateVolunteer( volunteer );
                JsonReturn retVal;// = new JsonReturn( rId, data, ConvertHttpStatus( HttpStatusCode.OK ), null );

                if ( data != null )
                {
                    retVal = new JsonReturn( rId, data, ConvertHttpStatus( HttpStatusCode.Created ), null );

                    var link = new Link { Rel = "self", Href = "/api/v1/Volunteers/" + data.Id + "/" };
                    retVal.Links.Add( link );

                    response = Request.CreateResponse( HttpStatusCode.Created, retVal );//Return response.
                    response.Headers.Add( "Location", "/api/v1/Volunteers/" + data.Id + "/" );
                }
                else
                {
                    retVal = new JsonReturn( rId, null, ConvertHttpStatus( HttpStatusCode.NotFound ), null );
                    response = Request.CreateResponse( HttpStatusCode.NotFound, retVal );//Return response.
                }

                //Log
                bal.CreateRequestLogEntry( rId, "OK", Request.RequestUri.PathAndQuery, Request.Method.Method, this.GetClientIp( Request ) );

                return response;
            }
            catch ( Exception ex )
            {
                bal.CreateRequestLogEntry( rId, "Expectation Failed", Request.RequestUri.PathAndQuery, Request.Method.Method, this.GetClientIp( Request ) );
                return Request.CreateErrorResponse( HttpStatusCode.ExpectationFailed, new HttpError( ex, true ) );
            }
        }
        public HttpResponseMessage GetVolunteers( int offset = 0, int limit = 5 )
        {
            var rId = bal.GetRequestId();

            try
            {
                var data = bal.GetVolunteers( offset, limit );
                var stats = bal.GetSystemStats();
                var xTotal = stats.TotalVolunteers;
                var retVal = new JsonReturn( rId, data, ConvertHttpStatus( HttpStatusCode.OK ), null );

                //Paging.
                var newPrevOffset = 0;
                var newNextOffset = offset + limit;

                //Previous paging.
                if ( offset > 0 )
                {
                    try
                    {
                        newPrevOffset = offset - limit;
                    }
                    catch ( Exception )
                    { }

                    var previous = new Link { Rel = "previous", Href = "/api/v1/Volunteers?offset=" + newPrevOffset + "&limit=5" };
                    retVal.Links.Add( previous );
                }

                //Next paging.
                if ( newNextOffset < xTotal )
                {
                    var next = new Link { Rel = "next", Href = "/api/v1/Volunteers?offset=" + newNextOffset + "&limit=5" };
                    retVal.Links.Add( next );
                }

                //Return response.
                var response = Request.CreateResponse( HttpStatusCode.OK, retVal );
                response.Headers.Add( "X-Total-Count", xTotal.ToString( CultureInfo.InvariantCulture ) );

                //Log
                bal.CreateRequestLogEntry( rId, "OK", Request.RequestUri.PathAndQuery, Request.Method.Method, this.GetClientIp( Request ) );

                return response;
            }
            catch ( Exception ex )
            {
                bal.CreateRequestLogEntry( rId, "Expectation Failed", Request.RequestUri.PathAndQuery, Request.Method.Method, this.GetClientIp( Request ) );
                return Request.CreateErrorResponse( HttpStatusCode.ExpectationFailed, new HttpError( ex, true ) );
            }
        }
        public HttpResponseMessage GetVolunteerFoodBank( int id )
        {
            var rId = bal.GetRequestId();

            try
            {
                JsonReturn retVal;
                HttpResponseMessage response;

                var data = bal.GetVolunteerFoodBank( id );

                if ( data != null )
                {
                    retVal = new JsonReturn( rId, data, ConvertHttpStatus( HttpStatusCode.OK ), null );

                    var link = new Link { Rel = "self", Href = "/api/v1/FoodBanks/" + id + "/" };
                    retVal.Links.Add( link );

                    response = Request.CreateResponse( HttpStatusCode.OK, retVal );//Return response.
                }
                else
                {
                    retVal = new JsonReturn( rId, null, ConvertHttpStatus( HttpStatusCode.NotFound ), null );
                    response = Request.CreateResponse( HttpStatusCode.NotFound, retVal );//Return response.
                }

                //Log
                bal.CreateRequestLogEntry( rId, "OK", Request.RequestUri.PathAndQuery, Request.Method.Method, this.GetClientIp( Request ) );

                return response;
            }
            catch ( Exception ex )
            {
                bal.CreateRequestLogEntry( rId, "Expectation Failed", Request.RequestUri.PathAndQuery, Request.Method.Method, this.GetClientIp( Request ) );
                return Request.CreateErrorResponse( HttpStatusCode.ExpectationFailed, new HttpError( ex, true ) );
            }
        }
        public HttpResponseMessage GetStats()
        {
            var rId = bal.GetRequestId();

            try
            {
                var data = bal.GetSystemStats();
                var retVal = new JsonReturn( rId, data, ConvertHttpStatus( HttpStatusCode.OK ), null );

                //Return response.
                var response = Request.CreateResponse( HttpStatusCode.OK, retVal );

                //Links.
                var next = new Link { Rel = "self", Href = "/api/v1/FoodBanks/" };
                retVal.Links.Add( next );

                next = new Link { Rel = "self", Href = "/api/v1/Donations/" };
                retVal.Links.Add( next );

                next = new Link { Rel = "self", Href = "/api/v1/Volunteers/" };
                retVal.Links.Add( next );

                //Log
                bal.CreateRequestLogEntry( rId, "OK", Request.RequestUri.PathAndQuery, Request.Method.Method, this.GetClientIp( Request ) );

                return response;
            }
            catch ( Exception ex )
            {
                bal.CreateRequestLogEntry( rId, "Expectation Failed", Request.RequestUri.PathAndQuery, Request.Method.Method, this.GetClientIp( Request ) );
                return Request.CreateErrorResponse( HttpStatusCode.ExpectationFailed, new HttpError( ex, true ) );
            }
        }