protected function getSourceAsArray($source)
    {
        if (!is_array($source) && !($source instanceof ArrayAccess)) {
            user_error('$source passed in as invalid type', E_USER_ERROR);
        }
        
        if ($source instanceof SS_List || $source instanceof Map) {
            $source = $source->toArray();
        }
        
        return $source;
    }