summaryrefslogtreecommitdiffstats
path: root/util
diff options
context:
space:
mode:
authorGravatar nadiramra2010-06-03 22:10:38 +0000
committerGravatar nadiramra2010-06-03 22:10:38 +0000
commit0c9712eee68c1ba673f5041fbab529f3b9f2e277 (patch)
treee1791bbe6b3cd9cdafc6d8ea833d611430543f0d /util
parent914851ec152f8a6293a0e35ebf28505eabae1ef6 (diff)
downloadaxis2c-0c9712eee68c1ba673f5041fbab529f3b9f2e277.tar.gz
axis2c-0c9712eee68c1ba673f5041fbab529f3b9f2e277.tar.bz2
AXIS2C-1384 axutil_date_time_get_date() should be axutil_date_time_get_day()
git-svn-id: http://svn.apache.org/repos/asf/axis/axis2/c/core/trunk@951181 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'util')
-rw-r--r--util/include/axutil_date_time.h6
-rw-r--r--util/src/date_time.c8
-rw-r--r--util/src/rand.c2
-rw-r--r--util/test/date_time/date_time_test.c2
4 files changed, 13 insertions, 5 deletions
diff --git a/util/include/axutil_date_time.h b/util/include/axutil_date_time.h
index eeac9e6..4276386 100644
--- a/util/include/axutil_date_time.h
+++ b/util/include/axutil_date_time.h
@@ -216,13 +216,13 @@ extern "C"
const axutil_env_t * env);
/**
- * retrieve the date of the date time
+ * retrieve the day of the date time
* @param date_time represet the type object
* @param env pointer to environment struct. MUST NOT be NULL
- * @return date as an integer
+ * @return day as an integer
*/
AXIS2_EXTERN int AXIS2_CALL
- axutil_date_time_get_date(
+ axutil_date_time_get_day(
axutil_date_time_t * date_time,
const axutil_env_t * env);
diff --git a/util/src/date_time.c b/util/src/date_time.c
index ad15774..55f26d5 100644
--- a/util/src/date_time.c
+++ b/util/src/date_time.c
@@ -731,6 +731,7 @@ axutil_date_time_get_month(
return (date_time->mon + 1);
}
+/* Deprecated...should have been get_day, remove in 1.8 */
AXIS2_EXTERN int AXIS2_CALL
axutil_date_time_get_date(
axutil_date_time_t *date_time,
@@ -738,6 +739,13 @@ axutil_date_time_get_date(
{
return (date_time->day);
}
+AXIS2_EXTERN int AXIS2_CALL
+axutil_date_time_get_day(
+ axutil_date_time_t *date_time,
+ const axutil_env_t *env)
+{
+ return (date_time->day);
+}
AXIS2_EXTERN int AXIS2_CALL
axutil_date_time_get_hour(
diff --git a/util/src/rand.c b/util/src/rand.c
index c3a7aa9..44057a8 100644
--- a/util/src/rand.c
+++ b/util/src/rand.c
@@ -57,7 +57,7 @@ axutil_rand_get_seed_value_based_on_time(
axutil_date_time_t *date = axutil_date_time_create(env);
unsigned int rand_var = axutil_date_time_get_year(date, env);
rand_var += axutil_date_time_get_month(date, env);
- rand_var += axutil_date_time_get_date(date, env);
+ rand_var += axutil_date_time_get_day(date, env);
rand_var += axutil_date_time_get_hour(date, env);
rand_var += axutil_date_time_get_minute(date, env);
rand_var += axutil_date_time_get_second(date, env);
diff --git a/util/test/date_time/date_time_test.c b/util/test/date_time/date_time_test.c
index 553fada..53d5d8c 100644
--- a/util/test/date_time/date_time_test.c
+++ b/util/test/date_time/date_time_test.c
@@ -99,7 +99,7 @@ axis2_status_t test_date_time(axutil_env_t *env)
}
year = axutil_date_time_get_year(date_time,env);
month=axutil_date_time_get_month(date_time,env);
- date = axutil_date_time_get_date(date_time,env);
+ date = axutil_date_time_get_day(date_time,env);
hour = axutil_date_time_get_hour(date_time,env);
min = axutil_date_time_get_minute(date_time,env);
sec = axutil_date_time_get_second(date_time,env);