This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//What I'm trying to work out stylistically is that is it a code smell to do something like, calling into an object heirachy | |
//Like this => this.setFirstName(order.getCustomer().getFirstName()); | |
//The "ORDER" creates a "CUSTOMER", the "CUSTOMER" has properties that the order calls down into | |
public class Usage { | |
public OrderResponse createOrder(CustomerOrder order) { | |
OrderProcessor processor = new OrderProcessor(); | |
CustomerOrderPayload customerOrderPayload = new CustomerOrderPayload() {{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
namespace ArrayStructure | |
{ | |
public struct Maybe<T> | |
{ | |
readonly IEnumerable<T> values; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections.Generic; | |
using System.Linq; | |
using NUnit.Framework; | |
//Using Maybe.cs | |
namespace ArrayStructure | |
{ | |
[TestFixture] | |
public class Tests | |
{ |