Horde_Kolab_Storage_Object_MimeType::getObjectTypeFromMimePart PHP 메소드

getObjectTypeFromMimePart() 공개 정적인 메소드

Determine the object type based on a specific MIME part that carries a Kolab object.
public static getObjectTypeFromMimePart ( Horde_Mime_Part $structure, string $id ) : string | boolean
$structure Horde_Mime_Part A structural representation of the mime message.
$id string The MIME part carrying the Kolab object.
리턴 string | boolean The object type or false if no matching object type was found.
    public static function getObjectTypeFromMimePart(Horde_Mime_Part $structure, $id)
    {
        return self::getObjectTypeFromMimeType($structure->getPart($id)->getType());
    }

Usage Example

예제 #1
0
 public function testGetUnknownObjectType()
 {
     $this->assertFalse(Horde_Kolab_Storage_Object_MimeType::getObjectTypeFromMimePart($this->getMultipartMimeMessage('dummy/dummy'), 2));
 }