As Margaret said, it would be a permitting issue to be addressed by the town. Typically, if a structure is within 75Ft of the high water mark it is considered non-conforming yet grandfathered for it's current use. In your case that is a boathouse. If you'd like to convert it's use, the town may require you to make it a conforming structure - which would mean it would have to be moved. There's many twists and turns to shoreland zoning. You can visit the Boothbay Harbor town website and download a copy of the shoreland zone rules.
Dabney Lewis is the local codes officer. Good luck!