libDXF 0.0.1
A library with DXF related functions written in C.
|
Header file for a DXF binary entity data object. More...
#include "global.h"
Go to the source code of this file.
Data Structures | |
struct | dxf_binary_entity_data_struct |
DXF definition of an AutoCAD binary entity data object. More... | |
Typedefs | |
typedef struct dxf_binary_entity_data_struct | DxfBinaryEntityData |
DXF definition of an AutoCAD binary entity data object. | |
Functions | |
DxfBinaryEntityData * | dxf_binary_entity_data_new () |
Allocate memory for a binary entity data object. | |
DxfBinaryEntityData * | dxf_binary_entity_data_init (DxfBinaryEntityData *data) |
Allocate memory and initialize data fields in a binary entity data entity. | |
int | dxf_binary_entity_data_write (DxfFile *fp, DxfBinaryEntityData *data) |
Write DXF output to fp for a binary entity data object. | |
int | dxf_binary_entity_data_free (DxfBinaryEntityData *data) |
Free the allocated memory for a binary entity data object and all it's data fields. | |
void | dxf_binary_entity_data_free_chain (DxfBinaryEntityData *data) |
Free the allocated memory for a chain of binary entity data bobjects and all their data fields. | |
char * | dxf_binary_entity_data_get_data_line (DxfBinaryEntityData *data) |
Get the data_line from a binary entity data object. | |
DxfBinaryEntityData * | dxf_binary_entity_data_set_data_line (DxfBinaryEntityData *data, char *data_line) |
Set the data_line for a binary entity data object. | |
int | dxf_binary_entity_data_get_length (DxfBinaryEntityData *data) |
Get the length from a binary entity data object. | |
DxfBinaryEntityData * | dxf_binary_entity_data_set_length (DxfBinaryEntityData *data, int length) |
Set the length for a binary entity data object. | |
DxfBinaryEntityData * | dxf_binary_entity_data_get_next (DxfBinaryEntityData *data) |
Get the pointer to the next binary entity data object from a binary entity data object. | |
DxfBinaryEntityData * | dxf_binary_entity_data_set_next (DxfBinaryEntityData *data, DxfBinaryEntityData *next) |
Set the pointer to the next binary entity data for a binary entity data entity. | |
DxfBinaryEntityData * | dxf_binary_entity_data_get_last (DxfBinaryEntityData *data) |
Get the pointer to the last binary entity data object from a linked list of binary entity data objects. |
Header file for a DXF binary entity data object.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to:
Free Software Foundation, Inc.,
59 Temple Place,
Suite 330,
Boston,
MA 02111 USA.
Drawing eXchange Format (DXF) is a defacto industry standard for the exchange of drawing files between various Computer Aided Drafting programs.
DXF is an industry standard designed by Autodesk(TM).
For more details see http://www.autodesk.com.
Definition in file binary_entity_data.h.
typedef struct dxf_binary_entity_data_struct DxfBinaryEntityData |
DXF definition of an AutoCAD binary entity data object.
DxfBinaryEntityData* dxf_binary_entity_data_new | ( | ) |
Allocate memory for a binary entity data object.
Fill the memory contents with zeros.
Definition at line 44 of file binary_entity_data.c.
References _, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.
Referenced by dxf_acad_proxy_entity_init(), and dxf_binary_entity_data_init().
DxfBinaryEntityData* dxf_binary_entity_data_init | ( | DxfBinaryEntityData * | data | ) |
Allocate memory and initialize data fields in a binary entity data entity.
NULL
when no memory was allocated, a pointer to the allocated memory when succesful. data | a pointer to the binary entity data object. |
Definition at line 82 of file binary_entity_data.c.
References _, dxf_binary_entity_data_new(), dxf_binary_entity_data_set_data_line(), dxf_binary_entity_data_set_next(), DXF_DEBUG_BEGIN, and DXF_DEBUG_END.
Referenced by dxf_acad_proxy_entity_init().
int dxf_binary_entity_data_write | ( | DxfFile * | fp, |
DxfBinaryEntityData * | data | ||
) |
Write DXF output to fp for a binary entity data object.
EXIT_SUCCESS
when done, or EXIT_FAILURE
when an error occurred. fp | file pointer to output file (or device). |
data | a pointer to the binary entity data object. |
Definition at line 122 of file binary_entity_data.c.
References _, dxf_binary_entity_data_struct::data_line, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_file_struct::fp.
int dxf_binary_entity_data_free | ( | DxfBinaryEntityData * | data | ) |
Free the allocated memory for a binary entity data object and all it's data fields.
EXIT_SUCCESS
when done, or EXIT_FAILURE
when an error occurred. data | Pointer to the memory occupied by the binary entity data entity. |
Definition at line 158 of file binary_entity_data.c.
References _, dxf_binary_entity_data_struct::data_line, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_binary_entity_data_struct::next.
Referenced by dxf_binary_entity_data_free_chain().
void dxf_binary_entity_data_free_chain | ( | DxfBinaryEntityData * | data | ) |
Free the allocated memory for a chain of binary entity data bobjects and all their data fields.
data | pointer to the chain of DXF HATCH binary entity data objects. |
Definition at line 198 of file binary_entity_data.c.
References _, dxf_binary_entity_data_free(), DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_binary_entity_data_struct::next.
char* dxf_binary_entity_data_get_data_line | ( | DxfBinaryEntityData * | data | ) |
Get the data_line from a binary entity data object.
NULL
when an error occurred. data | a pointer to a binary entity data object. |
Definition at line 233 of file binary_entity_data.c.
References _, dxf_binary_entity_data_struct::data_line, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.
DxfBinaryEntityData* dxf_binary_entity_data_set_data_line | ( | DxfBinaryEntityData * | data, |
char * | data_line | ||
) |
Set the data_line for a binary entity data object.
data | a pointer to a binary entity data object. |
data_line | a string containing the data_line for the entity. |
Definition at line 268 of file binary_entity_data.c.
References _, dxf_binary_entity_data_struct::data_line, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.
Referenced by dxf_binary_entity_data_init().
int dxf_binary_entity_data_get_length | ( | DxfBinaryEntityData * | data | ) |
Get the length
from a binary entity data object.
length
. data | a pointer to a binary entity data object. |
Definition at line 308 of file binary_entity_data.c.
References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_binary_entity_data_struct::length.
DxfBinaryEntityData* dxf_binary_entity_data_set_length | ( | DxfBinaryEntityData * | data, |
int | length | ||
) |
Set the length
for a binary entity data object.
data
when sucessful, NULL
when an error occurred. data | a pointer to a binary entity data object. |
length | Length to be set for the entity. |
Definition at line 346 of file binary_entity_data.c.
References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_binary_entity_data_struct::length.
DxfBinaryEntityData* dxf_binary_entity_data_get_next | ( | DxfBinaryEntityData * | data | ) |
Get the pointer to the next binary entity data object from a binary entity data object.
data | a pointer to a binary entity data object. |
Definition at line 389 of file binary_entity_data.c.
References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_binary_entity_data_struct::next.
DxfBinaryEntityData* dxf_binary_entity_data_set_next | ( | DxfBinaryEntityData * | data, |
DxfBinaryEntityData * | next | ||
) |
Set the pointer to the next binary entity data for a binary entity data entity.
data | a pointer to a binary entity data object. |
next | a pointer to the next binary entity data for the entity. |
Definition at line 425 of file binary_entity_data.c.
References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_binary_entity_data_struct::next.
Referenced by dxf_binary_entity_data_init().
DxfBinaryEntityData* dxf_binary_entity_data_get_last | ( | DxfBinaryEntityData * | data | ) |
Get the pointer to the last binary entity data object from a linked list of binary entity data objects.
data | a pointer to a binary entity data object. |
Definition at line 469 of file binary_entity_data.c.
References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_binary_entity_data_struct::next.