11package com .wordnik .swagger .models .properties ;
22
3+ import org .slf4j .Logger ;
4+ import org .slf4j .LoggerFactory ;
5+
36import java .util .*;
47
58public class PropertyBuilder {
9+ static Logger LOGGER = LoggerFactory .getLogger (PropertyBuilder .class );
10+
611 public static Property build (String type , String format , Map <String , Object > args ) {
712 if (args == null ) {
813 args = new HashMap <String , Object >();
@@ -92,7 +97,7 @@ public static Property build(String type, String format, Map<String, Object> arg
9297 // fallbacks
9398 if ("integer" .equals (type ) && format == null ) {
9499 // fall back to Integer if type is integer and format is missing
95- System . out . println ("no format specified for integer type, falling back to int32" );
100+ LOGGER . debug ("no format specified for integer type, falling back to int32" );
96101 property = new IntegerProperty ()
97102 .minimum (minimum )
98103 .maximum (maximum )
@@ -101,11 +106,11 @@ public static Property build(String type, String format, Map<String, Object> arg
101106 }
102107 if ("object" .equals (type ) && format == null ) {
103108 // fall back to Map if type is object and format is missing
104- System . out . println ("no format specified for object type, falling back to object" );
109+ LOGGER . debug ("no format specified for object type, falling back to object" );
105110 property = new ObjectProperty ();
106111 }
107112 if (property == null )
108- System . out . println ("no property for " + type + ", " + format );
113+ LOGGER . debug ("no property for " + type + ", " + format );
109114 return property ;
110115 }
111116}
0 commit comments