All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.bugvm.apple.coremedia.CMBlockBuffer Maven / Gradle / Ivy

There is a newer version: 1.2.9
Show newest version
/*
 * Copyright (C) 2013-2015 RoboVM AB
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.bugvm.apple.coremedia;

/**/
import java.io.*;
import java.nio.*;
import java.util.*;
import com.bugvm.objc.*;
import com.bugvm.objc.annotation.*;
import com.bugvm.objc.block.*;
import com.bugvm.rt.*;
import com.bugvm.rt.annotation.*;
import com.bugvm.rt.bro.*;
import com.bugvm.rt.bro.annotation.*;
import com.bugvm.rt.bro.ptr.*;
import com.bugvm.apple.foundation.*;
import com.bugvm.apple.corefoundation.*;
import com.bugvm.apple.dispatch.*;
import com.bugvm.apple.coreaudio.*;
import com.bugvm.apple.coregraphics.*;
import com.bugvm.apple.corevideo.*;
import com.bugvm.apple.audiotoolbox.*;
/**/

/**/
/**/
/**/@Library("CoreMedia")/**/
/**/public/**/ class /**/CMBlockBuffer/**/ 
    extends /**/CFType/**/ 
    /**//**/ {

    /**/public static class CMBlockBufferPtr extends Ptr {}/**/
    /**/static { Bro.bind(CMBlockBuffer.class); }/**/
    /**//**/
    /**/
    protected CMBlockBuffer() {}
    /**/
    /**//**/
    /**//**/
    /**
     * @throws OSStatusException 
     * @since Available in iOS 4.0 and later.
     */
    public static CMBlockBuffer create(int subBlockCapacity, CMBlockBufferFlags flags) throws OSStatusException {
        CMBlockBuffer.CMBlockBufferPtr ptr = new CMBlockBuffer.CMBlockBufferPtr();
        OSStatus status = create0(null, subBlockCapacity, flags, ptr);
        OSStatusException.throwIfNecessary(status);
        return ptr.get();
    }
    /**
     * @throws OSStatusException 
     * @since Available in iOS 4.0 and later.
     */
    public static CMBlockBuffer create(VoidPtr memoryBlock, @MachineSizedUInt long blockLength, CFAllocator blockAllocator, CMBlockBufferCustomBlockSource customBlockSource, @MachineSizedUInt long offsetToData, @MachineSizedUInt long dataLength, CMBlockBufferFlags flags) throws OSStatusException {
        CMBlockBuffer.CMBlockBufferPtr ptr = new CMBlockBuffer.CMBlockBufferPtr();
        OSStatus status = create0(null, memoryBlock, blockLength, blockAllocator, customBlockSource, offsetToData, dataLength, flags, ptr);
        OSStatusException.throwIfNecessary(status);
        return ptr.get();
    }
    /**
     * @throws OSStatusException 
     * @since Available in iOS 4.0 and later.
     */
    public static CMBlockBuffer create(CMBlockBuffer targetBuffer, @MachineSizedUInt long offsetToData, @MachineSizedUInt long dataLength, CMBlockBufferFlags flags) throws OSStatusException {
        CMBlockBuffer.CMBlockBufferPtr ptr = new CMBlockBuffer.CMBlockBufferPtr();
        OSStatus status = create0(null, targetBuffer, offsetToData, dataLength, flags, ptr);
        OSStatusException.throwIfNecessary(status);
        return ptr.get();
    }
    /**
     * @throws OSStatusException 
     * @since Available in iOS 4.0 and later.
     */
    public static CMBlockBuffer create(CMBlockBuffer sourceBuffer, CFAllocator blockAllocator, CMBlockBufferCustomBlockSource customBlockSource, @MachineSizedUInt long offsetToData, @MachineSizedUInt long dataLength, CMBlockBufferFlags flags) throws OSStatusException {
        CMBlockBuffer.CMBlockBufferPtr ptr = new CMBlockBuffer.CMBlockBufferPtr();
        OSStatus status = create0(null, sourceBuffer, blockAllocator, customBlockSource, offsetToData, dataLength, flags, ptr);
        OSStatusException.throwIfNecessary(status);
        return ptr.get();
    }
    /**
     * @throws OSStatusException 
     * @since Available in iOS 4.0 and later.
     */
    public void appendMemoryBlock(VoidPtr memoryBlock, long blockLength, CFAllocator blockAllocator, CMBlockBufferCustomBlockSource customBlockSource, long offsetToData, long dataLength, CMBlockBufferFlags flags) throws OSStatusException {
        OSStatus status = appendMemoryBlock0(memoryBlock, blockLength, blockAllocator, customBlockSource, offsetToData, dataLength, flags);
        OSStatusException.throwIfNecessary(status);
    }
    /**
     * @throws OSStatusException 
     * @since Available in iOS 4.0 and later.
     */
    public void appendBufferReference(CMBlockBuffer targetBBuf, long offsetToData, long dataLength, CMBlockBufferFlags flags) throws OSStatusException {
        OSStatus status = appendBufferReference0(targetBBuf, offsetToData, dataLength, flags);
        OSStatusException.throwIfNecessary(status);
    }
    /**
     * @throws OSStatusException 
     * @since Available in iOS 4.0 and later.
     */
    public void assureBlockMemory() throws OSStatusException {
        OSStatus status = assureBlockMemory0();
        OSStatusException.throwIfNecessary(status);
    }
    /**
     * @throws OSStatusException 
     * @since Available in iOS 4.0 and later.
     */
    public BytePtr accessDataBytes(long offset, @MachineSizedUInt long length, VoidPtr temporaryBlock) throws OSStatusException {
        BytePtr.BytePtrPtr ptr = new BytePtr.BytePtrPtr();
        OSStatus status = accessDataBytes0(this, offset, length, temporaryBlock, ptr);
        OSStatusException.throwIfNecessary(status);
        return ptr.get();
    }
    /**
     * @throws OSStatusException 
     * @since Available in iOS 4.0 and later.
     */
    public void copyDataBytes(long offsetToData, long dataLength, VoidPtr destination) throws OSStatusException {
        OSStatus status = copyDataBytes0(offsetToData, dataLength, destination);
        OSStatusException.throwIfNecessary(status);
    }
    /**
     * @throws OSStatusException 
     * @since Available in iOS 4.0 and later.
     */
    public void replaceDataBytes(VoidPtr sourceBytes, long offsetIntoDestination, long dataLength) throws OSStatusException {
        OSStatus status = replaceDataBytes0(sourceBytes, this, offsetIntoDestination, dataLength);
        OSStatusException.throwIfNecessary(status);
    }
    /**
     * @throws OSStatusException 
     * @since Available in iOS 4.0 and later.
     */
    public void fillDataBytes(byte fillByte, long offsetIntoDestination, long dataLength) throws OSStatusException {
        OSStatus status = fillDataBytes0(fillByte, this, offsetIntoDestination, dataLength);
        OSStatusException.throwIfNecessary(status);
    }
    /**/
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferCreateEmpty", optional=true)
    protected static native OSStatus create0(CFAllocator structureAllocator, int subBlockCapacity, CMBlockBufferFlags flags, CMBlockBuffer.CMBlockBufferPtr newBBufOut);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferCreateWithMemoryBlock", optional=true)
    protected static native OSStatus create0(CFAllocator structureAllocator, VoidPtr memoryBlock, @MachineSizedUInt long blockLength, CFAllocator blockAllocator, CMBlockBufferCustomBlockSource customBlockSource, @MachineSizedUInt long offsetToData, @MachineSizedUInt long dataLength, CMBlockBufferFlags flags, CMBlockBuffer.CMBlockBufferPtr newBBufOut);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferCreateWithBufferReference", optional=true)
    protected static native OSStatus create0(CFAllocator structureAllocator, CMBlockBuffer targetBuffer, @MachineSizedUInt long offsetToData, @MachineSizedUInt long dataLength, CMBlockBufferFlags flags, CMBlockBuffer.CMBlockBufferPtr newBBufOut);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferCreateContiguous", optional=true)
    protected static native OSStatus create0(CFAllocator structureAllocator, CMBlockBuffer sourceBuffer, CFAllocator blockAllocator, CMBlockBufferCustomBlockSource customBlockSource, @MachineSizedUInt long offsetToData, @MachineSizedUInt long dataLength, CMBlockBufferFlags flags, CMBlockBuffer.CMBlockBufferPtr newBBufOut);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferGetTypeID", optional=true)
    public static native @MachineSizedUInt long getClassTypeID();
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferAppendMemoryBlock", optional=true)
    protected native OSStatus appendMemoryBlock0(VoidPtr memoryBlock, @MachineSizedUInt long blockLength, CFAllocator blockAllocator, CMBlockBufferCustomBlockSource customBlockSource, @MachineSizedUInt long offsetToData, @MachineSizedUInt long dataLength, CMBlockBufferFlags flags);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferAppendBufferReference", optional=true)
    protected native OSStatus appendBufferReference0(CMBlockBuffer targetBBuf, @MachineSizedUInt long offsetToData, @MachineSizedUInt long dataLength, CMBlockBufferFlags flags);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferAssureBlockMemory", optional=true)
    protected native OSStatus assureBlockMemory0();
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferAccessDataBytes", optional=true)
    protected static native OSStatus accessDataBytes0(CMBlockBuffer theBuffer, @MachineSizedUInt long offset, @MachineSizedUInt long length, VoidPtr temporaryBlock, BytePtr.BytePtrPtr returnedPointer);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferCopyDataBytes", optional=true)
    protected native OSStatus copyDataBytes0(@MachineSizedUInt long offsetToData, @MachineSizedUInt long dataLength, VoidPtr destination);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferReplaceDataBytes", optional=true)
    protected static native OSStatus replaceDataBytes0(VoidPtr sourceBytes, CMBlockBuffer destinationBuffer, @MachineSizedUInt long offsetIntoDestination, @MachineSizedUInt long dataLength);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferFillDataBytes", optional=true)
    protected static native OSStatus fillDataBytes0(byte fillByte, CMBlockBuffer destinationBuffer, @MachineSizedUInt long offsetIntoDestination, @MachineSizedUInt long dataLength);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferGetDataPointer", optional=true)
    protected native OSStatus getDataPointer0(@MachineSizedUInt long offset, MachineSizedUIntPtr lengthAtOffset, MachineSizedUIntPtr totalLength, BytePtr.BytePtrPtr dataPointer);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferGetDataLength", optional=true)
    public native @MachineSizedUInt long getDataLength();
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferIsRangeContiguous", optional=true)
    public native boolean isRangeContiguous(@MachineSizedUInt long offset, @MachineSizedUInt long length);
    /**
     * @since Available in iOS 4.0 and later.
     */
    @Bridge(symbol="CMBlockBufferIsEmpty", optional=true)
    public native boolean isEmpty();
    /**/
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy