Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/fadeevab/design-patterns-rust
/ functions
Functions
277 in github.com/fadeevab/design-patterns-rust
⨍
Functions
277
◇
Types & classes
119
Function
main
()
creational/prototype/main.rs:8
Method
mileage
(&self)
creational/builder/components.rs:47
Method
name
(&self)
behavioral/mediator/mediator-rc-refcell/trains/passenger_train.rs:18
Method
name
(&self)
behavioral/mediator/mediator-top-down/trains/passenger_train.rs:15
Method
name
(&self)
creational/static-creation-method/main.rs:24
Method
new
(route_strategy: T)
behavioral/strategy/conceptual.rs:30
Method
new
(route_strategy: RouteStrategy)
behavioral/strategy/functional.rs:19
Method
new
(next: impl Department + 'static)
behavioral/chain-of-responsibility/department/medical.rs:8
Method
new
(next: impl Department + 'static)
behavioral/chain-of-responsibility/department/doctor.rs:8
Method
new
(next: impl Department + 'static)
behavioral/chain-of-responsibility/department/reception.rs:9
Method
new
(title: &'static str, duration: u32)
behavioral/state/player.rs:9
Method
new
(name: String, mediator: Rc<RefCell<dyn Mediator>>)
behavioral/mediator/mediator-rc-refcell/trains/freight_train.rs:12
Method
new
(name: String, mediator: Rc<RefCell<dyn Mediator>>)
behavioral/mediator/mediator-rc-refcell/trains/passenger_train.rs:12
Method
new
(name: &'static str)
behavioral/mediator/mediator-top-down/trains/freight_train.rs:9
Method
new
(name: &'static str)
behavioral/mediator/mediator-top-down/trains/passenger_train.rs:9
Method
new
Returns a custom user collection.
behavioral/iterator/users.rs:8
Method
new
(device: D)
structural/bridge/remotes/basic.rs:10
Method
new
(device: D)
structural/bridge/remotes/advanced.rs:10
Method
new
(name: &'static str)
structural/composite/fs/folder.rs:9
Method
new
(name: &'static str)
structural/composite/fs/file.rs:8
Method
new
(name: String)
structural/facade/account.rs:6
Method
new
()
structural/facade/wallet.rs:6
Method
new
(account_id: String, code: u32)
structural/facade/wallet_facade.rs:16
Method
new
(code: u32)
structural/facade/security_code.rs:6
Method
new
()
structural/proxy/server/nginx.rs:13
Method
new
(color: TreeColor, _name: String, _data: String)
structural/flyweight/forest/tree.rs:32
Method
new
(adaptee: SpecificTarget)
structural/adapter/adapter.rs:9
Method
new
(id: u32)
creational/simple-factory/button/id.rs:8
Method
new
(title: String)
creational/simple-factory/button/title.rs:8
Method
new
(title: String)
creational/factory-method/maze-game/magic_maze.rs:9
Method
new
(id: u32)
creational/factory-method/maze-game/ordinary_maze.rs:9
Method
new
(volume: f64, mileage: f64)
creational/builder/components.rs:23
Method
new
( car_type: CarType, seats: u16, engine: Engine, transmission: Transmission,
creational/builder/cars/car.rs:13
Method
new
( car_type: CarType, seats: u16, engine: Engine, transmission: Transmission,
creational/builder/cars/manual.rs:12
Method
new
"Static creation method" is actually a Rust's idiomatic way to define a "constructor".
creational/static-creation-method/main.rs:8
Method
next
(&mut self)
behavioral/chain-of-responsibility/department/cashier.rs:18
Method
next
(&mut self)
behavioral/chain-of-responsibility/department/medical.rs:25
Method
next
(&mut self)
behavioral/chain-of-responsibility/department/reception.rs:26
Method
next
A `next` method is the only `Iterator` trait method which is mandatory to be implemented. It makes accessible a huge range of standard methods, e.g. `
behavioral/iterator/users.rs:41
Method
off
(&mut self)
creational/builder/components.rs:35
Method
on
(&mut self)
creational/builder/components.rs:31
Method
parse_str
(&self, input: &str)
behavioral/visitor/main.rs:31
Method
parse_vec
(&self, input: Vec<i32>)
behavioral/visitor/main.rs:34
Method
play
(self: Box<Self>, player: &mut Player)
behavioral/state/state.rs:29
Method
press
(&self)
creational/abstract-factory/windows-gui/button.rs:6
Method
print_status
(&self)
structural/bridge/device/radio.rs:49
Function
public_transport_strategy
(from: &str, to: &str)
behavioral/strategy/functional.rs:7
Method
render
(&self)
creational/simple-factory/button/title.rs:14
Method
render
(&self)
creational/factory-method/render-dialog/gui.rs:13
Method
render
(&self)
creational/factory-method/render-dialog/windows_gui.rs:6
Method
render
(&self)
creational/factory-method/maze-game/ordinary_maze.rs:15
Method
request
(&self)
structural/adapter/adapter.rs:15
Method
request
(&self)
structural/adapter/target.rs:8
Method
restore
Deserializes an originator into a string of JSON format.
behavioral/memento/serde.rs:18
Method
rooms
(&self)
creational/factory-method/maze-game/ordinary_maze.rs:35
Method
route
(&self)
creational/builder/components.rs:75
Function
save_listener
(file_path: String)
behavioral/observer/main.rs:25
Method
search
(&self, keyword: &str)
structural/composite/fs/folder.rs:22
Method
seats
(&self)
creational/builder/cars/car.rs:43
Method
set_car_type
(&mut self, car_type: CarType)
creational/builder/builders/car_manual.rs:21
Method
set_channel
(&mut self, channel: u16)
structural/bridge/device/radio.rs:45
Method
set_engine
(&mut self, engine: Engine)
creational/builder/builders/car_manual.rs:25
Method
set_fuel
(&mut self, fuel: f64)
creational/builder/cars/car.rs:39
Method
set_gsp_navigator
(&mut self, gps_navigator: GpsNavigator)
creational/builder/builders/car_manual.rs:29
Method
set_seats
(&mut self, seats: u16)
creational/builder/builders/car_manual.rs:33
Method
set_transmission
(&mut self, transmission: Transmission)
creational/builder/builders/car_manual.rs:37
Method
set_volume
(&mut self, percent: u8)
structural/bridge/device/radio.rs:37
Method
surname
(&self)
creational/static-creation-method/main.rs:28
Method
switch
(&self)
creational/abstract-factory/windows-gui/checkbox.rs:6
Method
track
(&self)
behavioral/state/player.rs:61
Method
transmission
(&self)
creational/builder/cars/car.rs:51
Function
undo
Pops the last command and executes an undo action.
behavioral/command/main.rs:46
Method
undo
(&mut self, app: &mut Cursive)
behavioral/command/command/paste.rs:23
Method
undo
(&mut self, _: &mut Cursive)
behavioral/command/command/copy.rs:20
Method
volume
(&self)
structural/bridge/device/radio.rs:33
Method
volume
(&self)
creational/builder/components.rs:43
Function
walking_strategy
(from: &str, to: &str)
behavioral/strategy/functional.rs:3
← previous
201–277 of 277, ranked by callers