Pchp.Core.PhpString.ChunkToBoolean C# (CSharp) Метод

ChunkToBoolean() статический приватный Метод

static private ChunkToBoolean ( object chunk ) : bool
chunk object
Результат bool
        static bool ChunkToBoolean(object chunk)
        {
            AssertChunkObject(chunk);

            if (chunk.GetType() == typeof(string)) return Convert.ToBoolean((string)chunk);
            if (chunk.GetType() == typeof(byte[])) Convert.ToBoolean((byte[])chunk);
            if (chunk.GetType() == typeof(PhpString)) ((PhpString)chunk).ToBoolean();
            if (chunk.GetType() == typeof(char[])) Convert.ToBoolean((char[])chunk);
            throw new ArgumentException();
        }