<commit_before>// Copyright 2015-2016, Cyrill @ <EMAIL> and the CoreStore contributors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package scope

import (
	"github.com/corestoreio/csfw/util/bufferpool"
	"github.com/corestoreio/csfw/util/errors"
)

// Perm is a bit set and used for permissions. Uint16 should be big enough.
type Perm uint16

// PermStore convenient helper contains all scope permission levels. The
// official core_config_data table and its classes to not support the GroupID
// scope, so that is the reason why PermStore does not have a GroupID.
const PermStore Perm = 1<<Default | 1<<Website | 1<<Store

// PermWebsite convenient helper contains default and website scope permission levels.
const PermWebsite Perm = 1<<Default | 1<<Website

// PermDefault convenient helper contains default scope permission level.
const PermDefault Perm = 1 << Default

// PermStoreReverse convenient helper to enforce hierarchy levels. Only used in
// config.scopedService implementation.
const PermStoreReverse Perm = 1 << Store

// PermWebsiteReverse convenient helper to enforce hierarchy levels. Only used in
// config.scopedService implementation.
const PermWebsiteReverse Perm = 1<<Store | 1<<Website

// All applies DefaultID, WebsiteID and StoreID scopes
func (bits Perm) All() Perm {
	return bits.Set(Default, Website, Store)
}
<commit_msg>store/scope: Fix typo in doc<commit_after>// Copyright 2015-2016, Cyrill @ Schumacher.fm and the CoreStore contributors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package scope

import (
	"github.com/corestoreio/csfw/util/bufferpool"
	"github.com/corestoreio/csfw/util/errors"
)

// Perm is a bit set and used for permissions. Uint16 should be big enough.
type Perm uint16

// PermStore convenient helper contains all scope permission levels. The
// official core_config_data table and its classes to not support the GroupID
// scope, so that is the reason why PermStore does not have a GroupID.
const PermStore Perm = 1<<Default | 1<<Website | 1<<Store

// PermWebsite convenient helper contains default and website scope permission levels.
const PermWebsite Perm = 1<<Default | 1<<Website

// PermDefault convenient helper contains default scope permission level.
const PermDefault Perm = 1 << Default

// PermStoreReverse convenient helper to enforce hierarchy levels. Only used in
// config.Scoped implementation.
const PermStoreReverse Perm = 1 << Store

// PermWebsiteReverse convenient helper to enforce hierarchy levels. Only used in
// config.Scoped implementation.
const PermWebsiteReverse Perm = 1<<Store | 1<<Website

// All applies DefaultID, WebsiteID and StoreID scopes
func (bits Perm) All() Perm {
	return bits.Set(Default, Website, Store)
}

{'fraction_non_alphanumeric': 0.07934811648410366, 'fraction_numerical': 0.013358268768367619, 'mean_word_length': 4.080054274084125, 'pattern_counts': {'":': 0, '<': 40, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4398116', 'n_tokens_mistral': 1002, 'n_tokens_neox': 947, 'n_words': 456}