File Operations in Go: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
Line 6: Line 6:
=Overview=
=Overview=


Basic file read and write, by reading or writing the entire file into and from memory, is provided by the [[Go Package ioutil|<code>ioutil</code> package]]. An entire file is read in memory with <code>ioutil.ReadFile()</code> and memory content can be written into a file with <code>ioutil.WriteFile()</code>: {{Internal|Go Package ioutil|Basic file read and write with <tt>ioutil</tt>}}
Basic file read and write, by reading or writing the entire file into and from memory, is provided by the [[Go Package ioutil|<code>ioutil</code> package]]. An entire file is read in memory with <code>ioutil.ReadFile()</code> and memory content can be written into a file with <code>ioutil.WriteFile()</code>: {{Internal|Go Package ioutil|Basic File Read and Write with <tt>ioutil</tt>}}

Revision as of 17:53, 25 August 2023

Internal

Overview

Basic file read and write, by reading or writing the entire file into and from memory, is provided by the ioutil package. An entire file is read in memory with ioutil.ReadFile() and memory content can be written into a file with ioutil.WriteFile():

Basic File Read and Write with ioutil