[Verification] Code compiles successfully.
Change-Id: Id81aa801f3858ead071ef8899cb9cfc4136ad589
Signed-off-by: Arkadiusz Pietraszek <a.pietraszek@partner.samsung.com>
return CheckFileStatus(path);
}
+void PrintDeprecationWarningFor(const char* className, const char* replacement) {
+ if (nullptr == replacement) {
+ LoggerW("DEPRECATION WARNING: %s is deprecated and using it is not recommended.",
+ className);
+ } else {
+ LoggerW("DEPRECATION WARNING: %s is deprecated and using it is not recommended. Try using %s instead",
+ className, replacement);
+ }
+
+}
+
} // namespace tools
} // namespace common
PlatformResult CheckFileAvailability(const std::string& path);
+void PrintDeprecationWarningFor(const char* className, const char* replacement = nullptr);
+
} // namespace tools
} // namespace common
return native_.getResultObject(result);
};
+Utils.prototype.printDeprecationWarningFor = function(name, replacement) {
+ if (_type.isUndefined(replacement)) {
+ this.warn('DEPRECATION WARNING: ' + name + ' is deprecated and using it is not recommended.');
+ } else {
+ this.warn('DEPRECATION WARNING: ' + name + ' is deprecated and using it is not recommended.'
+ + "Try using " + replacement + " instead.");
+ }
+};
+
/////////////////////////////////////////////////////////////////////////////
/** @constructor */