<?php
namespace Misuzu\Perms;

class PermissionResult implements IPermissionResult {
    use PermissionResultShared;

    public function __construct(private int $calculated) {}

    public function getCalculated(): int {
        return $this->calculated;
    }

    public function check(int $perm): bool {
        return ($this->calculated & $perm) > 0;
    }
}
