src/Shared/EntityFramework/Core/Objects/Internal/EntitySqlQueryBuilder.cs
// <summary>
// Helper method to extract the Entity-SQL command text from an <see cref="ObjectQueryState" /> instance if that
// instance models an Entity-SQL-backed ObjectQuery, or to throw an exception indicating that query builder methods
// are not supported on this query.
// </summary>
// <param name="query"> The instance from which the Entity-SQL command text should be retrieved </param>
// <returns> The Entity-SQL command text, if the specified query state instance is based on Entity-SQL </returns>
// <exception cref="NotSupportedException">If the specified instance is not based on Entity-SQL command text, and so does not support Entity-SQL query builder methods</exception>
Helper method to extract the Entity-SQL command text from an  instance if that
instance models an Entity-SQL-backed ObjectQuery, or to throw an exception indicating that query builder methods
are not supported on this query.
Helper method to extract the Entity - SQL command text from an instance if that instance models an Entity - SQL - backed ObjectQuery or to throw an exception indicating that query builder methods are not supported on this query .
private static string GetCommandText(ObjectQueryState query)
        {
            string commandText = null;
            if (!query.TryGetCommandText(out commandText))
            {
                throw new NotSupportedException(Strings.ObjectQuery_QueryBuilder_NotSupportedLinqSource);
            }
            return commandText;
        }
private static string GetCommandText ( ObjectQueryState query ) { string commandText = null ; if ( ! query . TryGetCommandText ( out commandText ) ) { throw new NotSupportedException ( Strings . ObjectQuery_QueryBuilder_NotSupportedLinqSource ) ; } return commandText ; }
Helper method to extract the Entity-SQL command text from an  instance if that
instance models an Entity-SQL-backed ObjectQuery, or to throw an exception indicating that query builder methods
are not supported on this query.
Helper method to extract the Entity - SQL command text from an instance if that instance models an Entity - SQL - backed ObjectQuery or to throw an exception indicating that query builder methods are not supported on this query .
The Entity-SQL command text, if the specified query state instance is based on Entity-SQL
The Entity - SQL command text if the specified query state instance is based on Entity - SQL
If the specified instance is not based on Entity-SQL command text, and so does not support Entity-SQL query builder methods
If the specified instance is not based on Entity - SQL command text and so does not support Entity - SQL query builder methods
query
ObjectQueryState
The instance from which the Entity-SQL command text should be retrieved
The instance from which the Entity - SQL command text should be retrieved