---
title: "init(upstream:receiveSubscription:receiveOutput:receiveCompletion:)"
framework: combine
role: symbol
role_heading: Initializer
path: "combine/publishers/breakpoint/init(upstream:receivesubscription:receiveoutput:receivecompletion:)"
---

# init(upstream:receiveSubscription:receiveOutput:receiveCompletion:)

Creates a breakpoint publisher with the provided upstream publisher and breakpoint-raising closures.

## Declaration

```swift
init(upstream: Upstream, receiveSubscription: ((any Subscription) -> Bool)? = nil, receiveOutput: ((Upstream.Output) -> Bool)? = nil, receiveCompletion: ((Subscribers.Completion<Publishers.Breakpoint<Upstream>.Failure>) -> Bool)? = nil)
```

## Parameters

- `upstream`: The publisher from which this publisher receives elements.
- `receiveSubscription`: A closure that executes when the publisher receives a subscription, and can raise a debugger signal by returning a true Boolean value.
- `receiveOutput`: A closure that executes when the publisher receives output from the upstream publisher, and can raise a debugger signal by returning a true Boolean value.
- `receiveCompletion`: A closure that executes when the publisher receives completion, and can raise a debugger signal by returning a true Boolean value.
