Skip to content
Browse files

moved time_utils stuff to clcg_datetime_utils

  • Loading branch information...
1 parent 1cac2ad commit a591540e3f9c9e3f818b2f0effe8a87f28e72f4b @ettore committed Nov 23, 2012
Showing with 7 additions and 71 deletions.
  1. +6 −1 clcg_datetime_utils.h
  2. +1 −0 clcg_datetime_utils.m
  3. +0 −44 clcg_time_utils.h
  4. +0 −26 clcg_time_utils.m
View
7 clcg_datetime_utils.h
@@ -29,7 +29,12 @@
#ifndef CLCG_DATETIME_UTILS_H_
#define CLCG_DATETIME_UTILS_H_
-#import <Foundation/Foundation.h>
+#define CLCG_MINUTE 60
+#define CLCG_HOUR (60 * CLCG_MINUTE)
+#define CLCG_DAY (24 * CLCG_HOUR)
+#define CLCG_WEEK (7 * CLCG_DAY)
+#define CLCG_MONTH (30.5 * CLCG_DAY)
+#define CLCG_YEAR (365 * CLCG_DAY)
#ifdef __cplusplus
extern "C" {
View
1 clcg_datetime_utils.m
@@ -27,6 +27,7 @@
//
#import "clcg_datetime_utils.h"
+#import "clcg_bundle_utils.h"
/** Get the year out of a date object. */
NSInteger clcg_date_year(NSDate *d)
View
44 clcg_time_utils.h
@@ -1,44 +0,0 @@
-// Copyright (c) 2011, Ettore Pasquini
-// Copyright (c) 2011, Cubelogic
-// All rights reserved.
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are met:
-//
-// - Redistributions of source code must retain the above copyright notice, this
-// list of conditions and the following disclaimer.
-// - Redistributions in binary form must reproduce the above copyright notice,
-// this list of conditions and the following disclaimer in the documentation
-// and/or other materials provided with the distribution.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-// ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
-// LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-// POSSIBILITY OF SUCH DAMAGE.
-
-#ifndef CLCG_TIME_UTILS_H_
-#define CLCG_TIME_UTILS_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#define CLCG_MINUTE 60
-#define CLCG_HOUR (60 * CLCG_MINUTE)
-#define CLCG_DAY (24 * CLCG_HOUR)
-#define CLCG_WEEK (7 * CLCG_DAY)
-#define CLCG_MONTH (30.5 * CLCG_DAY)
-#define CLCG_YEAR (365 * CLCG_DAY)
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
View
26 clcg_time_utils.m
@@ -1,26 +0,0 @@
-// Copyright (c) 2011, Ettore Pasquini
-// Copyright (c) 2011, Cubelogic
-// All rights reserved.
-//
-// Redistribution and use in source and binary forms, with or without
-// modification, are permitted provided that the following conditions are met:
-//
-// - Redistributions of source code must retain the above copyright notice, this
-// list of conditions and the following disclaimer.
-// - Redistributions in binary form must reproduce the above copyright notice,
-// this list of conditions and the following disclaimer in the documentation
-// and/or other materials provided with the distribution.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-// ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
-// LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-// POSSIBILITY OF SUCH DAMAGE.
-
-#import "clcg_time_utils.h"

0 comments on commit a591540

Please sign in to comment.
Something went wrong with that request. Please try again.