PsdSectionReader
ภาพรวม
PsdSectionReader เป็นคลาสใน Aspose.Psd FOSS สำหรับ Python.
ให้การอ่านแบบจำกัดสำหรับส่วน PSD/PSB ที่ถูกจัดเก็บในหน่วยความจำโดยการดำเนินการนี้.
คลาสนี้ประกาศ 5 เมธอดสำหรับอ็อบเจ็กต์ PsdSectionReader ในโปรแกรม Python. เมธอดที่มีให้รวมถึง: ReadBytes, get_memory_backed_length, get_nested_memory_backed_length, read_bytes, validate_signed_length. สมาชิกสาธารณะสามารถเข้าถึงได้จากแอปพลิเคชัน Python ใดก็ได้หลังจากติดตั้งแพ็กเกจ Aspose.Psd FOSS สำหรับ Python.
วิธีการ
| ลายเซ็น | คำอธิบาย |
|---|---|
read_bytes(reader: BigEndianReader, length: int, section_name: str) → bytes | อ่านข้อมูลส่วนที่ประกาศหลังจากตรวจสอบขอบเขตของสตรีมและขีดจำกัดขนาดในหน่วยความจำ. |
ReadBytes(reader: BigEndianReader, length: int, section_name: str) → bytes | เรียก ReadBytes(reader, length, section_name) บนอินสแตนซ์ PsdSectionReader นี้. |
get_memory_backed_length(reader: BigEndianReader, length: int, section_name: str) → int | ตรวจสอบความยาวของส่วนที่ประกาศและคืนขนาดอาร์เรย์ในหน่วยความจำที่เทียบเท่า. |
validate_signed_length(length: int, section_name: str) → int | ตรวจสอบฟิลด์ความยาวที่มีเครื่องหมายซึ่งเป็นของส่วนที่ถูกจำกัด. |
get_nested_memory_backed_length(reader: BigEndianReader, length: int, section_end: int, section_name: str) → int | ตรวจสอบให้แน่ใจว่าข้อมูลที่ซ้อนอยู่ยังคงอยู่ภายในส่วนที่ล้อมรอบที่ได้จำกัดไว้แล้ว. |