code: public static Integer getDays(String days)
     {
        Integer result = null;
        if (days != null)
        {
           result = Integer.valueOf(Integer.parseInt(days, 2));
        }
        return (result);
     }
docs: Converts the string representation of the days bit field into an integer.
  
  @param days string bit field
  @return integer bit field