lib/jss/api_object/self_servable/icon.rb
def save(path, overwrite = false)
        path = Pathname.new path
        path = path + @name if path.directory? && @name

        raise JSS::AlreadyExistsError, "The file #{path} already exists" if path.exist? unless overwrite
        path.delete if path.exist?
        path.jss_save @data
      end
# Save the icon to a file.
#
# @param path[Pathname, String] The path to which the file should be saved.
# If the path given is an existing directory, the icon's current filename will
# be used, if known.
#
# @param overwrite[Boolean] Overwrite the file if it exists? Defaults to false
#
# @return [void]
#
Save the icon to a file.
Save the icon to a file .
def save(path, overwrite = false)
        path = Pathname.new path
        path = path + @name if path.directory? && @name
        raise JSS::AlreadyExistsError, "The file #{path} already exists" if path.exist? unless overwrite
        path.delete if path.exist?
        path.jss_save @data
      end
def save ( path , overwrite = false ) path = Pathname . new path path = path + @name if path . directory? && @name raise JSS :: AlreadyExistsError , "The file #{path} already exists" if path . exist? unless overwrite path . delete if path . exist? path . jss_save @data end
Save the icon to a file.
Save the icon to a file .
None
void
path
The path to which the file should be saved. If the path given is an existing directory, the icon's current filename will be used, if known.
The path to which the file should be saved . If the path given is an existing directory the icon ' s current filename will be used if known .
overwrite
Overwrite the file if it exists. Defaults to false
Overwrite the file if it exists . Defaults to false