Skip to content

Commit ace122c

Browse files
committed
Code style
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/cli/trunk@779054 13f79535-47bb-0310-9956-ffa450edef68
1 parent 0e45f91 commit ace122c

2 files changed

Lines changed: 10 additions & 20 deletions

File tree

src/java/org/apache/commons/cli/CommandLine.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,8 +106,7 @@ public Object getOptionObject(String opt)
106106
* @throws ParseException if there are problems turning the option value into the desired type
107107
* @see PatternOptionBuilder
108108
*/
109-
public Object getParsedOptionValue(String opt)
110-
throws ParseException
109+
public Object getParsedOptionValue(String opt) throws ParseException
111110
{
112111
String res = getOptionValue(opt);
113112

src/java/org/apache/commons/cli/TypeHandler.java

Lines changed: 9 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,7 @@ public class TypeHandler
4343
* @return The instance of <code>obj</code> initialised with
4444
* the value of <code>str</code>.
4545
*/
46-
public static Object createValue(String str, Object obj)
47-
throws ParseException
46+
public static Object createValue(String str, Object obj) throws ParseException
4847
{
4948
return createValue(str, (Class) obj);
5049
}
@@ -58,8 +57,7 @@ public static Object createValue(String str, Object obj)
5857
* @return The instance of <code>clazz</code> initialised with
5958
* the value of <code>str</code>.
6059
*/
61-
public static Object createValue(String str, Class clazz)
62-
throws ParseException
60+
public static Object createValue(String str, Class clazz) throws ParseException
6361
{
6462
if (PatternOptionBuilder.STRING_VALUE == clazz)
6563
{
@@ -110,8 +108,7 @@ else if (PatternOptionBuilder.URL_VALUE == clazz)
110108
* @return the initialised object, or null if it couldn't create
111109
* the Object.
112110
*/
113-
public static Object createObject(String classname)
114-
throws ParseException
111+
public static Object createObject(String classname) throws ParseException
115112
{
116113
Class cl = null;
117114

@@ -146,8 +143,7 @@ public static Object createObject(String classname)
146143
* @return the number represented by <code>str</code>, if <code>str</code>
147144
* is not a number, null is returned.
148145
*/
149-
public static Number createNumber(String str)
150-
throws ParseException
146+
public static Number createNumber(String str) throws ParseException
151147
{
152148
try
153149
{
@@ -172,8 +168,7 @@ public static Number createNumber(String str)
172168
* @param classname the class name
173169
* @return The class if it is found, otherwise return null
174170
*/
175-
public static Class createClass(String classname)
176-
throws ParseException
171+
public static Class createClass(String classname) throws ParseException
177172
{
178173
try
179174
{
@@ -192,8 +187,7 @@ public static Class createClass(String classname)
192187
* @return The date if <code>str</code> is a valid date string,
193188
* otherwise return null.
194189
*/
195-
public static Date createDate(String str)
196-
throws ParseException
190+
public static Date createDate(String str) throws ParseException
197191
{
198192
throw new UnsupportedOperationException("Not yet implemented");
199193
}
@@ -205,8 +199,7 @@ public static Date createDate(String str)
205199
* @return The URL is <code>str</code> is well-formed, otherwise
206200
* return null.
207201
*/
208-
public static URL createURL(String str)
209-
throws ParseException
202+
public static URL createURL(String str) throws ParseException
210203
{
211204
try
212205
{
@@ -224,8 +217,7 @@ public static URL createURL(String str)
224217
* @param str the File location
225218
* @return The file represented by <code>str</code>.
226219
*/
227-
public static File createFile(String str)
228-
throws ParseException
220+
public static File createFile(String str) throws ParseException
229221
{
230222
return new File(str);
231223
}
@@ -236,8 +228,7 @@ public static File createFile(String str)
236228
* @param str the paths to the files
237229
* @return The File[] represented by <code>str</code>.
238230
*/
239-
public static File[] createFiles(String str)
240-
throws ParseException
231+
public static File[] createFiles(String str) throws ParseException
241232
{
242233
// to implement/port:
243234
// return FileW.findFiles(str);

0 commit comments

Comments
 (0)