Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitc9a00e2

Browse files
Get rid of StampVariated base class. It makes code more comples, instead of making it more simple
1 parenta3413df commitc9a00e2

File tree

2 files changed

+3
-18
lines changed

2 files changed

+3
-18
lines changed

‎blobstamper/stamp.h

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -107,16 +107,6 @@ StampBaseV<T>::ExtractBin(Blob &blob)
107107
return v;
108108
}
109109

110-
classStampVariated :publicvirtual StampBase
111-
{
112-
protected:
113-
int min_size;
114-
int max_size;
115-
public:
116-
virtualintminSize()override {return min_size;}
117-
virtualintmaxSize()override {return max_size;}
118-
};
119-
120110
classStampUnbounded :publicvirtual StampBase
121111
{
122112
protected:

‎t/test-chars-stamps.h

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -48,19 +48,14 @@ StampTwoChars::ExtractStr(Blob &blob)
4848
}
4949

5050
/*****************************************************************************/
51-
classStampSeveralChars:publicStampVariated,publicStampBaseStr
51+
classStampSeveralChars:publicStampBaseStr
5252
{
5353
public:
54-
StampSeveralChars();
54+
virtualintminSize()override {return2;}/* Minimal size of consumed data*/
55+
virtualintmaxSize()override {return8;}/* Maximal size of consumed data*/
5556
std::stringExtractStr(Blob &blob)override;
5657
};
5758

58-
StampSeveralChars::StampSeveralChars()
59-
{
60-
min_size =2;
61-
max_size =8;
62-
}
63-
6459
std::string
6560
StampSeveralChars::ExtractStr(Blob &blob)
6661
{

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp