GW2RegisterReportFile
The GW2RegisterReportFile function registers the file path where the engineering log file is to be placed. This API generates the report file only for debug builds of the Glasswall Engine.
- C++
- C#
- Java
- Python
- JavaScript
Synopsis
For session session, the GW2RegisterReportFile function registers the name of the file where the engineering log file is to be placed. The name is the string pointed to by reportFilePathName.
#include "glasswall.core2.api.h"
int GW2RegisterReportFile(Session session, const char *reportFilePathName);
Returns
Returns an integer GW2_RetStatus enum value. Negative numbers indicate a failure.
Synopsis
public int RegisterReportFile(
int session,
string reportFilePathName)
Returns
Returns an integer GW2_RetStatus enum value. Negative numbers indicate a failure.
Synopsis
import com.glasswall.core2javabridge.*;
public int GW2RegisterReportFile(int session, String reportFilePath) throws GlasswallException, NullPointerException
(Deprecated)
public int GW2RegisterReportFile(int session, byte[] reportFilePath) throws GlasswallException, NullPointerException
Description
The GW2RegisterReportFile function parameters have been updated to use String in place of byte[]. The original function has been deprecated.
Returns
The GW2RegisterReportFile function returns a GW2_RetStatus enumeration converted to int. The value will be negative if an error occurred. 0 indicates success. Refer to the API Overview/Return types for details.
A NullPointerException exception will be thrown if reportFilePath is null or empty.
A GlasswallException exception will be thrown if session is invalid, if the reportFilePath could not be retrieved, or if the reportFilePath could not be converted to UTF-8.
Synopsis
Registers the name of the file where the engineering log file is to be placed.
def register_report_file(self, session: int, output_file: str):
""" Register the report file path for the given session.
Args:
session (int): The session integer.
output_file (str): The file path of the report file.
Returns:
gw_return_object (glasswall.GwReturnObj): A GwReturnObj instance with the attributes 'session', 'output_file', 'status'.
"""
Returns
gw_return_object (glasswall.GwReturnObj): A GwReturnObj instance with the attributes 'session', 'output_file', 'status'.
Synopsis
This function registers the name of the file where the engineering log file is to be placed.
/**
* @param {number} session The ID of the session.
* @param {string} reportFilePathName The path of the file to be registered.
*/
GW2RegisterReportFile(session, reportFilePathName)
Returns
Returns an integer GW2_RetStatus enum value. Negative numbers indicate a failure.