Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
B
BDIO.jl
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Alberto Ramos
BDIO.jl
Commits
dc3344d5
Commit
dc3344d5
authored
Oct 22, 2019
by
Alberto Ramos
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added BDIO_close method
parent
02e9d648
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
2 deletions
+19
-2
docs/src/index.md
docs/src/index.md
+2
-1
src/BDIO.jl
src/BDIO.jl
+1
-1
src/BDIOmethods.jl
src/BDIOmethods.jl
+16
-0
No files found.
docs/src/index.md
View file @
dc3344d5
...
...
@@ -17,10 +17,11 @@ BDIO_set_user
BDIO_set_host
```
### Openning `BDIO` files
### Openning
/closing
`BDIO` files
```
@docs
BDIO_open
BDIO_close!
```
## Writing data to `BDIO` files
...
...
src/BDIO.jl
View file @
dc3344d5
...
...
@@ -21,6 +21,6 @@ export BDIO_BIN_GENERIC, BDIO_ASC_EXEC, BDIO_BIN_INT32BE,
# Methods
export
BDIOstream
,
BDIO_open
,
BDIO_start_record!
,
BDIO_write_hash!
,
BDIO_write!
,
BDIO_seek!
,
BDIO_get_len
,
BDIO_get_fmt
,
BDIO_get_uinfo
,
BDIO_read
,
BDIO_set_user
,
BDIO_set_host
BDIO_get_uinfo
,
BDIO_read
,
BDIO_set_user
,
BDIO_set_host
,
BDIO_close!
end
# module
src/BDIOmethods.jl
View file @
dc3344d5
...
...
@@ -79,6 +79,22 @@ function BDIO_open(fname::String, mode::String, protocol_info::String="")
return
fb
end
"""
Closes the file associated with fb and clears the record database
## Arguments
- `fb`: A BDIOstream type. It must be associated with a file.
## Examples
```julia-repl
julia> fb = BDIO_open("
new_file
.
bdio
", "
w
", "
Test
file
")
julia> BDIO_close(fb)
"""
function
BDIO_close
!
(
fb
)
close
(
fb
.
io
)
fb
.
records
=
similar
(
Array
{
record
,
1
},
0
)
end
"""
Start a new BDIO record at the end of the file. Currently the supported formats are
- `BDIO_BIN_GENERIC`: Generic binary data
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment