esoe
2 years ago
7 changed files with 40 additions and 7 deletions
@ -0,0 +1,24 @@
@@ -0,0 +1,24 @@
|
||||
package ru.molokoin; |
||||
|
||||
public class Conversion { |
||||
/** |
||||
* Проверяем содержимое объекта. |
||||
* |
||||
* @param object |
||||
* @return |
||||
*/ |
||||
public static Object checknull(Object object){ |
||||
Object result = new Object(); |
||||
if (object == null)throw new NullPointerException("Обнаружено пустое поле данных ..."); |
||||
|
||||
return (Object)result; |
||||
} |
||||
public static int toint(Object object){ |
||||
String s = (String) object; |
||||
return Integer.parseInt(s); |
||||
} |
||||
public static String toString(Object object){ |
||||
|
||||
return ""; |
||||
} |
||||
} |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
Reference in new issue