original_string: public function textDomain( $textDomain = self::DEFAULT_TEXT_DOMAIN,
                                  $locale     = null )
      {
          $translator = $this->getTranslator();
          $locale     = $locale ?: $translator->getLocale();
  
          if ( ! isset( $translator->myMessages[$textDomain][$locale] ) )
          {
              $translator->loadMyMessages( $textDomain, $locale );
          }
  
          if ( ! isset( $translator->messages[$textDomain][$locale] ) )
          {
              $translator->loadMessages( $textDomain, $locale );
          }
  
          $my     = $translator->myMessages[$textDomain][$locale];
          $global = $translator->messages[$textDomain][$locale];
  
          if ( $my instanceof TextDomain )
          {
              $my = $my->getArrayCopy();
          }
          else if ( empty( $my ) )
          {
              $my = array();
          }
  
          if ( $global instanceof TextDomain )
          {
              $global = $global->getArrayCopy();
          }
          else if ( empty( $global ) )
          {
              $global = array();
          }
  
          return array_replace( $global, $my );
      }
code: public function textDomain( $textDomain = self::DEFAULT_TEXT_DOMAIN,
                                  $locale     = null )
      {
          $translator = $this->getTranslator();
          $locale     = $locale ?: $translator->getLocale();
  
          if ( ! isset( $translator->myMessages[$textDomain][$locale] ) )
          {
              $translator->loadMyMessages( $textDomain, $locale );
          }
  
          if ( ! isset( $translator->messages[$textDomain][$locale] ) )
          {
              $translator->loadMessages( $textDomain, $locale );
          }
  
          $my     = $translator->myMessages[$textDomain][$locale];
          $global = $translator->messages[$textDomain][$locale];
  
          if ( $my instanceof TextDomain )
          {
              $my = $my->getArrayCopy();
          }
          else if ( empty( $my ) )
          {
              $my = array();
          }
  
          if ( $global instanceof TextDomain )
          {
              $global = $global->getArrayCopy();
          }
          else if ( empty( $global ) )
          {
              $global = array();
          }
  
          return array_replace( $global, $my );
      }
code_tokens: public function textDomain ( $ textDomain = self :: DEFAULT_TEXT_DOMAIN , $ locale = null ) { $ translator = $ this -> getTranslator ( ) ; $ locale = $ locale ? : $ translator -> getLocale ( ) ; if ( ! isset ( $ translator -> myMessages [ $ textDomain ] [ $ locale ] ) ) { $ translator -> loadMyMessages ( $ textDomain , $ locale ) ; } if ( ! isset ( $ translator -> messages [ $ textDomain ] [ $ locale ] ) ) { $ translator -> loadMessages ( $ textDomain , $ locale ) ; } $ my = $ translator -> myMessages [ $ textDomain ] [ $ locale ] ; $ global = $ translator -> messages [ $ textDomain ] [ $ locale ] ; if ( $ my instanceof TextDomain ) { $ my = $ my -> getArrayCopy ( ) ; } else if ( empty ( $ my ) ) { $ my = array ( ) ; } if ( $ global instanceof TextDomain ) { $ global = $ global -> getArrayCopy ( ) ; } else if ( empty ( $ global ) ) { $ global = array ( ) ; } return array_replace ( $ global , $ my ) ; }
docstring: Get a whole text-domain
  
  @param string $textDomain
  @param string|null $locale
  @return array
docstring_tokens: Get a whole text - domain