Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AlignedBuilder needs finer controls #85

Closed
samuelwilliams opened this issue Nov 16, 2020 · 1 comment
Closed

AlignedBuilder needs finer controls #85

samuelwilliams opened this issue Nov 16, 2020 · 1 comment
Assignees
Milestone

Comments

@samuelwilliams
Copy link
Contributor

Change AlignedBuilder around so that you can have some finer control on how things are done. As I said before, AlignedBuilder is designed around my arbitrary opinions, but it would be good if developers can add their own specialised handlers into the builder. This would be a BC-breaking change, but can be shipped with v4. I envisaged something like:

function myTxtHandler(Rdata\TXT $txt): string {
     //return text that is cut down into smaller chunks.
}

$builder = new AlignedBuilder();
                        //(string $type,  callable $renderer)
$builder->setRdataRenderer('TXT', 'myTxtHandler');

Originally posting in PR #83

@samuelwilliams samuelwilliams added this to the Version 4 milestone Nov 16, 2020
@samuelwilliams samuelwilliams self-assigned this Nov 16, 2020
@samuelwilliams samuelwilliams mentioned this issue Nov 30, 2020
samuelwilliams added a commit that referenced this issue Nov 30, 2020
* [Issue #85](#85) - `Badow\DNS\AlignedBuilder` now has finer controls. You can now
  define the order of rendering Resource Records and add or change Rdata output formatters (see `Docs/AlignedZoneBuilder`.
* `Badow\DNS\AlignedBuilder` cannot be called statically anymore. It must be instantiated.
* Update documentation
@samuelwilliams
Copy link
Contributor Author

PR #87

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant