aboutsummaryrefslogtreecommitdiffstats
path: root/src/sm-error.h
diff options
context:
space:
mode:
authorKazumasa Mitsunari <knimitz@witz-inc.co.jp>2018-03-28 21:03:23 +0900
committerKazumasa Mitsunari <knimitz@witz-inc.co.jp>2018-05-16 18:38:27 +0900
commitcbf280b545bbb3a879c55913564796f944b217c4 (patch)
tree0fa8345f5d396bca5d4049783fb914d1bb527880 /src/sm-error.h
parent975d5e70b89481c90df30365c660b3f5043c3150 (diff)
Clean: divide soundmanager.c into interface part and proxy part
* interface part ... soundmanager This receives request and send event to clients * proxy part ... am_proxy_audiomanager This is the proxy to call and receive audiomanager API Change-Id: If29643ba3356ec1d7ec87468b023cf8809aa4eb3 Signed-off-by: Kazumasa Mitsunari <knimitz@witz-inc.co.jp>
Diffstat (limited to 'src/sm-error.h')
-rw-r--r--src/sm-error.h70
1 files changed, 19 insertions, 51 deletions
diff --git a/src/sm-error.h b/src/sm-error.h
index 34d36b3..521fca2 100644
--- a/src/sm-error.h
+++ b/src/sm-error.h
@@ -1,52 +1,20 @@
-#ifndef SM_ERROR_H
-#define SM_ERROR_H
-
-char* get_response_audiomanager_massage_error(int am_error_code)
-{
- switch (am_error_code){
- case 0:
- return "OK";
- case 1:
- return "unknown error";
- case 2:
- return "value out of range";
- case 3:
- return "not used";
- case 4:
- return "database error occured";
- case 5:
- return "the desired object already exists";
- case 6:
- return "there is no change";
- case 7:
- return "the desired action is not possible";
- case 8:
- return "the desired object is non existent";
- case 9:
- return "the asynchronous action was aborted";
- case 10:
- return "connectionFormat is not selected";
- case 11:
- return "communication error";
- case 100:
- return "desired event doesn't exist";
- default:
- return "Audio Manager responsed unknown error number";
- }
-}
-
-char* get_source_state_key(int am_source_state){
- switch (am_source_state){
- case 0:
- return "unknown";
- case 1:
- return "on";
- case 2:
- return "off";
- case 3:
- return "paused";
- default:
- return "";
- }
-}
+/*
+ * Copyright (c) 2017 TOYOTA MOTOR CORPORATION
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+#ifndef SOUNDMANAGER_ERROR_H
+#define SOUNDMANAGER_ERROR_H
+const char* get_response_audiomanager_massage_error(int am_error_code);
+const char* get_source_state_key(int am_source_state);
#endif