Class: ClaudeAgentSDK::FileChangedHookInput

Inherits:
BaseHookInput show all
Defined in:
lib/claude_agent_sdk/types.rb

Overview

FileChanged hook input

Instance Attribute Summary collapse

Attributes inherited from BaseHookInput

#cwd, #permission_mode, #session_id, #transcript_path

Instance Method Summary collapse

Constructor Details

#initialize(hook_event_name: 'FileChanged', file_path: nil, event: nil, **base_args) ⇒ FileChangedHookInput

Returns a new instance of FileChangedHookInput.



1165
1166
1167
1168
1169
1170
# File 'lib/claude_agent_sdk/types.rb', line 1165

def initialize(hook_event_name: 'FileChanged', file_path: nil, event: nil, **base_args)
  super(**base_args)
  @hook_event_name = hook_event_name
  @file_path = file_path
  @event = event # "change", "add", or "unlink"
end

Instance Attribute Details

#eventObject

Returns the value of attribute event.



1163
1164
1165
# File 'lib/claude_agent_sdk/types.rb', line 1163

def event
  @event
end

#file_pathObject

Returns the value of attribute file_path.



1163
1164
1165
# File 'lib/claude_agent_sdk/types.rb', line 1163

def file_path
  @file_path
end

#hook_event_nameObject

Returns the value of attribute hook_event_name.



1163
1164
1165
# File 'lib/claude_agent_sdk/types.rb', line 1163

def hook_event_name
  @hook_event_name
end